Moments before the match went to penalties — it was goalless after extra-time — Chelsea boss Maurizio Sarri called for Kepa Arrizabalaga to be substituted after the goalkeeper appeared to have injured himself in making a save from Sergio Aguero.
But remarkably, the Spaniard defied the wishes of his manager, and refused to make way for Willy Caballero in extra-time. Although he saved one spot-kick, Sterling converted the decisive effort for City to deny Sarri, who is reportedly close to the sack, his first trophy as a manager.
A controversial start saw Jorginho escape punishment after appearing to elbow Sergio Aguero straight from kick-off before referee Jon Moss gave no foul when Oleksandr Zinchenko's challenge halted the progress of N'Golo Kante as the midfielder ran through on the City goal..
City had hammered Chelsea 6-0 at Etihad Stadium two weeks ago but Sarri's switch of system to use Eden Hazard as a false nine, with Gonzalo Higuain missing out, markedly boosted his side's defensive solidity.
Pep Guardiola claimed pre-match it was too early to talk about City's chances of winning an historic quadruple despite being in the FA Cup quarter-finals, leading its Round of 16 UEFA Champions League tie with Schalke and sitting neck-and-neck with Liverpool in the Premier League.
It didn't take too long for City to find its rhythm and Sergio Aguero rifled a shot over the crossbar before his deflected effort was easily claimed by Kepa in the first half.
City thought it had opened the scoring in the 56th minute but Aguero was rightly flagged offside and a video assistant referee (VAR) check upheld the decision.
Kante should have broken the deadlock but, after Hazard's dazzling run deceived City's half-time substitute Vincent Kompany, he blazed the perfect cutback over the crossbar.
Aguero and Sterling could not find a finishing touch in an extra-time goalmouth scramble before City's record goalscorer was denied by Kepa.
The Blues keeper required treatment twice in the added period but refused to be replaced by Caballero, who saved three penalties for City in the 2016 final, leaving Sarri absolutely furious.
In the shootout, Jorginho's tame opening effort was saved by Ederson to hand Chelsea an immediate advantage, but Kepa denied Leroy Sane and David Luiz hit the post.
Hazard's 'Panenka' effort kept Chelsea alive but Sterling crashed his strike in off the crossbar to retain the title for City and keep their quadruple hopes alive.
City's Premier League title challenge continues this week with a visit of West Ham United, and with Liverpool dropping points at Manchester United in another goalless draw, the Sky Blues have a real chance to apply more pressure on Jurgen Klopp's side.