Liverpool’s late win at Crystal Palace earlier in the day meant City started 12 points behind the leaders and looked in danger of failing to cut that gap when N’Golo Kante gave Chelsea a deserved lead midway through the first half.
However, Kevin de Bruyne’s deflected strike breathed new life into Pep Guardiola’s men and a trademark left-footed finish from Riyad Mahrez saw City edge a thrilling encounter.
Defeat ends a run of six straight Premier League wins for Frank Lampard’s Chelsea, but there was still plenty of encouragement for the Blues on a ground where they were thrashed 6-0 last season.
De Bruyne flashed a shot inches wide in a bright opening by the hosts as they sought to make amends for a 3-1 defeat to Liverpool in their last outing before the international break.
However, it was Chelsea who began to take control of the game in the first quarter.
Willian drilled wide at the end of a flowing counter-attack before Fikayo Tomori’s effort after a corner ricocheted around the City box also flew just off target.
There was no surprise when the visitors eventually took the lead 21 minutes in when Kante made the sort of run from midfield that Lampard made his trademark during his playing career before slotting the ball under Ederson from Mateo Kovacic’s wonderful pass.
City bemoaned their luck in defeat at Anfield a fortnight ago but got the slice of fortune they needed to gain a foothold back in the game eight minutes later when De Bruyne’s tame shot deflected off Kurt Zouma to leave Kepa Arrizabalaga wrong-footed.
Mahrez then turned the game on its head with a brilliant jinking run and finish into the far corner as City clicked into gear.
The champions should have been further ahead by the break as Kepa’s poor clearance gifted possession to Sergio Aguero, but the Argentine hit the bar with just the keeper to beat.
In a game that flowed from end-to-end, City could never feel comfortable with a single goal lead and Kante was close to his second when a goalbound shot was deflected behind by Fernandinho.
At the other end, a well-worked corner saw Mahrez pick out Joao Cancelo, but the Portuguese full-back did not get a clean strike away before Kepa prevented Mahrez sealing all three points.
Willian sent a dipping volley just over and Mason Mount’s free-kick was inches away from snatching a point for Chelsea late on.
But City’s margin of victory could have been even greater as Raheem Sterling found the bottom corner deep into stoppage time, only for VAR to rule the goal out for offside.