Their hopes looked to be dead and buried when substitute Ali Gibb was red carded in the 66th minute for his challenge on winger Kevan Hurst just five minutes after coming on to the pitch.
Scunthorpe were already 1-0 ahead thanks to a debut goal from Martin Paterson, who raced in unmarked in the 51st minute to find the net with a diving header from a cross by Cleveland Taylor.
Earlier Scunthorpe had dominated the opening half without being able to find their finishing touch.
Goalkeeper Jan Budtz pulled off a handful of fine saves but was beaten in the 41st minute by a close-range shot from Paul Hayes which crashed back into play off a post.
The home side were left to regret those early misses when Hartlepool suddenly found themselves back on level terms in the 70th minute when substitute David Foley took advantage of some sloppy play to squeeze a right-foot shot past goalkeeper Josh Lillis from level with the penalty spot.
Extra time seemed to be looming when Foley then struck again with an 85th minute winner as he measured a left-foot shot from the edge of the box into the bottom corner.
It sealed a great result for Hartlepool, who had thought they had got a penalty in the 15th minute when striker Ian Moore went down in the box only for referee Graham Salisbury to reverse his decision after consulting with the linesman and book the striker for diving.