Jesus headed home a Sergio Aguero cross in the 84th minute after Calum Chambers appeared to have secured three priceless points for the hosts in their unlikely battle to beat the drop.
Steve Agnew’s men led through a first-half strike from former City striker Alvaro Negredo before the visitors drew level in controversial fashion when Aguero netted from the spot.
Boro players reacted with fury when Leroy Sane went down under the challenge of Marten de Roon - but reacted brilliantly to grab back the lead just seven minutes later.
But in a thrilling finale Jesus, back after 10 weeks out with a foot injury, strengthened his side’s top-four prospects and left Boro six points off safety with just three games to go.
Boro had almost behind in the first 30 seconds, Aguero wriggling into the left side of the box and flashing a shot across the face of goal.
Aleksandar Kolarov drove a long-range effort high and wide with three minutes on the clock, and five minutes later Fernandinho’s lofted pass fed Aguero who scooped his shot inches over the bar.
But Boro survived the early storm and began to flourish, their confidence visibly returning after ending their long winless streak in midweek which boosted their still-unlikely survival mission.
Ben Gibson flicked on a Fabio cross in the 12th minute to Negredo, who blazed his shot across the face of goal from a tight angle.
De Roon shot wide from long range then the same player just missed the target after latching onto the end of a deep Downing free-kick.
Jesus, who had cut a relatively anonymous figure in the first half hour, came close with his first chance of note when he flicked wide from Nicolas Otamendi’s right-wing cross.
And Boro grabbed the lead their initiative deserved in the 37th minute when de Roon sent Downing scampering clear down the left flank and when his cross was laid back from George Friend inside the box, Negredo sent a curling left-foot finish past Willy Caballero.
After just four minutes of the second half, during which Caballero plucked the ball off the head of the dangerous de Roon, Guardiola had seen enough and threw on both Leroy Sane and Raheem Sterling to bolster his side’s attacking threat.
Inevitably City began to pile on the pressure, Kevin De Bruyne stinging Brad Guzan’s hands with a long-range effort before the Boro keeper had to be alert on 65 minutes to tip over a clever lofted effort by Jesus Navas.
Tempers frayed two minutes later when Sane fell under a challenge by de Roon in the box and after referee Kevin Friend pointed to the spot the Boro players reacted with fury, with Fabio booked for protesting and Sane having to be pulled away from a confrontation.
Aguero dispatched the spot-kick but just three minutes later there was more drama at the other end when Boro substitute Adama Traore burst clear but fell under the challenge of Otamendi on the edge of the box.
Downing’s free-kick was spilled by Otamendi and after a mighty goalmouth scramble, Negredo managed to squeeze the ball across the face of goal at the second attempt where Chambers poked home.
But the drama was not over as Jesus rose unchallenged in the Boro box to head home an Aguero cross and grab the equaliser with four minutes to go.