Gael Givet's extra-time header put Blackburn through to the Carling Cup last eight at the expense of Newcastle.
Rovers took an early lead when Ruben Rochina blasted in from 12 yards before Yakubu doubled the lead from the spot in the second-half.
Injury-time strikes from Danny Guthrie and Yohan Cabaye forced extra time.
Morten Gamst Pedersen scored a free-kick, Peter Lovenkrands' penalty levelled from the spot before Givet popped up with the late winner.
Towards the end of normal time it looked as though Blackburn were certain to reach the quarter-finals for the fourth time in five seasons, but in-form Newcastle were not going to give up their unbeaten start to the season easily and stunned the home fans with their late double.
Alan Pardew's side came into the game with an 11-game undefeated run in all competitions, which sees them sitting level with Chelsea in the Premier League - 14 points ahead of rock-bottom Rovers, who have won just one league game so far.
Blackburn fans protested before their last two home games, demanding the dismissal of boss Steve Kean, but this battling performance may appease some of the unhappy supporters.
Rochina set Blackburn off to a flying start with a fifth-minute strike after Martin Olsson broke down the wing before pulling the ball back into the path of the Spaniard, who struck from 12 yards.
Newcastle thought they had a penalty after the restart when Christopher Samba appeared to bring down Demba Ba in the area, but it was at the other end that a spot kick was awarded when keeper Tim Krul upended Rochina in the area after 64 minutes and Yakubu calmly slotted home.
But just as Rovers were poised to celebrate their first victory over Premier League opposition in the Carling Cup since 2009, the visitors staged a late comeback when Guthrie scored from 25 yards in the 93rd minute after the Rovers defence backed off.
And in the sixth minute of stoppage time Cabaye forced extra-time when he hit a 20-yard free kick after Samba fouled substitute Lovenkrands.
Blackburn were back in front nine minutes into extra time thanks to Pedersen's 35-yard free-kick, which took a deflection off the Newcastle wall before flying past Krul.
However, Newcastle were soon on level terms once more when Cabaye was deemed to have been pulled back in the area by the assistant referee and Lovenkrands stepped up to put away the resulting spot kick.
Just as penalties looked to be on the cards, Pedersen swung in a free-kick that Samba headed back across the goal for Givet to head home from just a yard out with the Newcastle defence appealing for offside.
Blackburn Rovers manager Steve Kean:
"Gael Givet encapsulates the whole spirit we have got here - he had a hamstring nick but would not come off. He's a warrior, he has put his head where other people wouldn't put their feet. He was fantastic.
"It's tough mentally when they scored so late to go and score again but we did it.
"We are always going to score goals but we have been working day in, day out defensively so that when we lose possession we get a good shape."
Newcastle manager Alan Pardew:
"I don't like the tag of gallant losers but it was a fantastic effort and the fans would have appreciated the effort we have put in.
"Some times events just go against you and events certainly did tonight. But the players don't know when to give in, we kept going and two great hits got us back into the game, but tiredness cost us at the end.
"If we are going to go out of the cup that's how it should be - giving it everything."