Slaven Bilic's side came into the game full of confidence following consecutive victories over Crystal Palace and Middlesbrough which saw them move into the top half of the table.
But the Hammers failed to reach the same standards and could do nothing to stop Pep Guardiola's side recording another victory in east London, following their FA Cup victory at the start of January.
Goals from Kevin De Bruyne, David Silva. Gabriel Jesus and a second half penalty from Yaya Toure helped City record an emphatic victory.
Bilic made one change from the team that recorded a 3-1 win over Middlesbrough in the last game as he handed a Premier League debut to new signing Jose Fonte following his £8million from Southampton.
But the Portuguese defender suffered a frustrating evening in his first start for the club and could do nothing to stop a rampant Manchester City side.
The away side opened the scoring on 17 minutes after Aaron Cresswell lost possession on the halfway line.
De Bruyne burst clear into the West Ham and played a neat interchange with Jesus before slotting the ball past Darren Randolph into the corner of the net.
City doubled their lead on 20 minutes when Leroy Sane nutmegged Sam Byram and raced towards the byeline before cutting the ball back for Silva who had the easy task of knocking the ball home from close-range.
The Hammers blew a golden chance to get back into the game on 32 minutes when Andy Carroll played the perfect ball into the path of Aaron Cresswell who was through on goal.
The Hammers full-back took a great first touch but with just Willy Caballero to beat in the City goal he fired his shot high over the bar.
City made the home side pay as they made it three on 39 minutes as new signing Jesus grabbed his first goal following his move at the start of January.
Sane was involved in the build-up once again as he picked out Raheem Sterling and the City winger squared the ball for new signing Jesus who made no mistake tapping the ball home.
City completed the rout on 65 minutes after Fonte brought down Sterling inside the area.
Toure slotted the spot kick past Randolph into the corner of the net.
Bilic will be hoping his players can bounce straight back when they travel to play Southampton at St Mary's Stadium on Saturday.
West Ham: Randolph; Byram, Fonte, Reid, Cresswell; Obiang (Snodgrass 64), Noble; Feghouli (Fernandes 64), Lanzini, Antonio; Carroll (Fletcher 79)
Subs not used: Adrian, Collins, Calleri, Quina.
Bookings: Obiang, Lanzini, Carroll
Manchester City: Cabellero; Sagna, Stones, Otamendi, Kolarov; Toure; Silva (Delph 80), Sane, De Bruyne (Fernandinho 67), Sterling (Aguero 73); Jesus
Subs not used: Bravo, Zabaleta, Kompany, Navas
Bookings: De Bruyne, Sterling, Jesus
Referee: Kevin Friend