Sergio Aguero converted a 59th minute penalty to leave City a point off League leaders Liverpool and keep their quadruple hopes alive.
Fresh from defeating Chelsea in the Carabao Cup finals, an under-par Manchester City where able to gain all three points and keep apace with Liverpool at the top of the table.
City should have had a first-half lead but David Silva effort was saved by the upright while Ederson did well to save from Andy Carroll after the interval.
Pep Guardiola brought on Raheem Sterling and Bernardo Silva for Mahrez and Leroy Sane and it was the Portuguese whose presence had the most effect.
The former Monaco man was bundled over by Felipe Anderson in the box before Sergio Aguero converted the resulting spot kick to give City the lead.
Lukasz Fabianski prevented Sterling and Danilo from increasing the deficit but his hardwork wasn’t enough as his outfield teammates couldn’t find away back into the match.
DOWNLOAD VIDEO: Man City 1 vs 0 West Ham