Sunderland grabbed a last-gasp winner to move to within three points of an automatic promotion place after overcoming previous Championship leaders Derby County at the Stadium of Light.
Liam Miller struck the decisive blow in time added on with a deft header from substitute Grant Leadbitter's left-wing cross after the Rams had hit back with a storming second-half performance.
David Connolly put the Black Cats ahead with a well-taken 27th-minute penalty only for substitute Giles Barnes to haul the Rams level with a stunning solo effort on the hour mark.
Sunderland were in charge from the outset with the leaders unable to find any pattern or rhythm as they strove to stem the tide of almost one-way traffic.
The Black Cats were close to taking the lead in the 11th minute after Tobias Hysen, receiving the ball from Connolly, cut inside Marc Edworthy only to pull his close-range effort across the face of goal.
A delicate 25-yard chip from Dwight Yorke sailed over Stephen Bywater's head and drifted just the wrong side of the post and only a series of niggling free-kicks broke up the relentless pressure.
The Black Cats were not to be denied however, and made the crucial breakthrough in the 27th minute. Edworthy tugged at the shirt of Connolly right in front of referee Martin Atkinson who immediately pointed the penalty spot.
Connolly made no mistake from the spot-kick, Sunderland's first penalty since November 2005, sending Bywater the wrong way to take his tally of goals for the season into double figures.
The home side missed a great chance to increase their lead two minutes later, Stern John failing to connect cleanly from Danny Simpson's cross from only a couple of yards out.
John missed another great opportunity when Jonny Evans turned Edwards' centre back into the middle.
Derby rallied briefly with Darren Ward turning a free-kick from Gary Teale behind and then forcing the keeper to save his close range header under the bar.
That was to be the last action for Teale, Barnes replacing him at the start of the second half. The substitute had an instant impact as suddenly the Black Cats were penned back deep into their own half.
Stephen Pearson headed over from close range when completely unmarked and, when Danny Collins challenged Steven Howard in the air the ball ballooned over Darren Ward only for the keeper to somehow turn the ball over the bar.
Ward tipped a pile-driver from Pearson over the bar and Collins headed off the line with Ward beaten from a Howard header but the Rams deservedly drew level on the hour when Barnes glided his way past three defenders to score a wonderful solo goal.
Suddenly the game had been turned on its head, substitute Daryl Murphy struck the post and though both teams went all out for the winner, a draw seemed the likely outcome until Miller's late winner.