Cape Town - Pedro Rodriguez came off the bench to halt Chelsea's slide with an extra-time winner in a 2-1 victory at Leicester on Sunday to reach the FA Cup semi-finals.
Alvaro Morata's first goal since Boxing Day on his return to the Chelsea starting line-up put the visitors on course to bounce back from their Champions League elimination at the hands of Barcelona in midweek.
However, Jamie Vardy's equaliser 15 minutes from time made them do it the hard way in an extra 30 minutes.
Yet, for all Antonio Conte's complaints this season about his side's strength in depth, the Italian was able to call on Pedro to turn the game in Chelsea's favour when he headed home former Leicester favourite N'Golo Kante's cross.
Chelsea had lost three of their past four matches to fall behind in the race for a top-four finish in the Premier League as well as their European exit.
But victory does at least keep their chances of silverware to end the season alive.
Chelsea will meet Southampton in the last four, while Manchester United face Tottenham Hotspur for a place in the final.
Both Morata and Pedro had a point to prove after being left out of the Spain squad on Friday just three months ahead of the World Cup.
Morata was recalled for just his second start since the sides last met in a 0-0 draw at Stamford Bridge back in January.
And after a quiet start, Chelsea's club record £70-million buy from Real Madrid was presented with his first big chance of the afternoon when he was brilliantly picked out by Marcos Alonso's low cross, but his shot was far too close to Kasper Schmeichel.
Morata ends drought
Morata headed another half-chance from a teasing Willian cross over and then hit the outside of the post from the narrowest of angles.
The goal he craved finally arrived three minutes before halftime, but much of the credit must go to Willian who surged through the heart of the Leicester midfield on the counter-attack before feeding Morata.
And Morata coolly clipped the ball beyond the advancing Schmeichel with an assuredness unbefitting of a striker who had gone 13 games without a goal.
Despite going in front, Conte still withdrew Tiemoue Bakayoko at half-time after another awful 45 minutes for the Frenchman in a desperately disappointing debut season in English football following a £40 million move from Monaco.
The visitors were happy to take their chances on the counter-attack in the second period as they began to feel the after-effects of their run around at Barcelona in midweek.
Leicester's search for an equaliser was largely laboured and, even when a big chance did arise, Vardy headed wastefully over when completely unmarked inside the area.
However, the England international made amends 15 minutes from time when he forced the ball home at the third attempt after Vicente Iborra's first two efforts were blocked and then saved by Willy Caballero.
Only a fine low save from Caballero prevented Vardy from turning the tie completely around eight minutes later as both sides settled for extra time.
Crucially, Conte was able to refresh his side as Pedro, Gary Cahill and Olivier Giroud were all introduced in the first half of extra time.
And it was Pedro who proved the match winner in unfamiliar fashion as he rose to outjump Schmeichel and nod into an unguarded net.