Substitute Romelu Lukaku rescued Inter with a 119th-minute winner to knock Fiorentina out of the Coppa Italia with a 2-1 win for the second season running.
Lukaku started from the bench ahead of Sunday's Derby d'Italia against Juventus but was called for in the second half after Christian Kouame had cancelled out Arturo Vidal's penalty opener.
There was no immediate impact as the Nerazzurri sought to get their season back on track, having taken just a point from their prior two Serie A matches.
Yet Lukaku made his mark deep into extra time at the Artemio Franchi, powering a header past Pietro Terracciano to book Inter's place in the quarter-finals, where they will meet Milan.
This was a tame affair until a frantic finish to the first half when Christian Eriksen's shot was spilled by Terracciano, who felled Alexis Sanchez as the follow-up squirmed beyond the goalkeeper and against the post.
A spot-kick was awarded only after referee Davide Massa consulted the pitchside monitor, but Vidal took full advantage.
Massa was swiftly called to the screen again to correct a second errant call, this time initially giving a foul against Milan Skriniar for a well-timed tackle on Kouame inside the area.
There was no reprieve for Inter when Kouame controlled a poor clearance and lashed into the top-right corner three minutes before the hour, however.
Lautaro Martinez had remarkably blasted wide prior to that strike and Sanchez was the next visiting star to pass up a big opportunity as he failed to turn in Ivan Perisic's cross.
Routine saves at either end took the match to extra time, where another Perisic centre deflected onto the crossbar and Sanchez was again wasteful in nodding straight at Terracciano.
Fiorentina looked to have reached a shoot-out when Terracciano blocked from Lukaku, but the striker decisively made amends with a second header to settle the tie.
What does it mean? Inter so reliant on Rom
Despite having Sanchez in reserve, Antonio Conte has picked Lukaku and Martinez whenever possible in Serie A this season, the pair playing 1154 and 1173 minutes respectively.
Given this weekend's vital fixture against Juve, the coach would have hoped he could cope without Lukaku for this one, only to see Inter taken the distance, a blow to their ambitions on Sunday.
So it was Lukaku, who has 12 goals and three assists in the league, who had to make the difference again. Conte will pray he still has something left in the tank.
Christian creating again
Seemingly set to depart San Siro and starting for the first time in a month, Eriksen was quietly impressive in an unfamiliar role, his average position just ahead of the back three.
Even from this deeper posting, no Inter player created more chances (four), played more passes in the Fiorentina half (46) or had more shots on target (two) than the ex-Tottenham midfielder, who completed the 120 minutes.
Forwards firing blanks
Sanchez also saw out the duration and won the penalty for the opener, but he allowed Vidal to take the kick after a recent miss against Sampdoria and otherwise failed to turn an energetic display into a goal threat, twice caught offside and attempting only two shots despite some presentable openings.
Meanwhile, Martinez did not trouble the target with any of his four efforts and contributed the miss of the match before being replaced by Lukaku after 69 minutes.
It is the big one for Inter, who must arrest their Serie A slump against the champions in Milan. Fiorentina also play on Sunday, visiting Napoli.