Danny Batth's first league goal for two years and substitute Mame Diouf's injury-time winner saw Stoke snatch a dramatic 2-1 victory over fellow strugglers Wigan.
Defender Batth's 55th-minute equaliser spared new manager Michael O'Neill defeat in his first home league game in charge of the Potters.
And Diouf's late goal sunk the Latics, who had been on course for what would have been only their second win in 30 away matches.
Earlier Wigan skipper Sam Morsy's first league goal for two years gave the visitors a welcome 39th-minute lead and hope of ending their four-game winless run.
The Egypt midfielder fired home after a howler from Stoke keeper Jack Butland just before the break.
The former England international's attempted clearance smashed into team-mate Tom Edwards and Morsy mopped up from the mistake.
But Batth poked home from James McLean's free-kick and then Diouf pounced at the death to complete a remarkable turnaround.
The hosts started the brighter with Wigan keeper David Marshall forced to produce a smart save to deny the lively McLean after only three minutes.
And less than a minute later McLean turned provider with an inch-perfect cross for Nick Powell but the midfielder frustratingly headed against the bar.
Winger Tom Ince had a glorious chance to put the hosts ahead in the seventh minute, but his composure let him down as he blazed over from the edge of the box.
The visitors finally came to life on the quarter-hour mark when Jamal Lowe whipped a dangerous ball across the face of goal and the recalled Gavin Massey, one of four changes for the visitors, came within inches of scoring.
Lewis MacLeod burst forward and had a shot charged down on the edge of the area and Paul Cook's side should have taken the lead through leading scorer Chey Dunkley, but the unmarked centre-back headed agonisingly wide from point-blank range from Charlie Mulgrew's corner.
Scottland shot-stopper Marshall had to be alert to thwart Stephen Ward just after the half-hour as the home side pushed for the opener.
But it was at the other end of the pitch that the breakthrough came thanks to Butland's error as Morsy gladly fired into an open net.
Stoke started brightly at the beginning of the second half and McLean nearly scored a brilliant solo goal.
His bursting run saw him beat four defenders, but defender Antonee Robinson managed to get in a vital block as McLean pulled the trigger in the area.
The equaliser then came through Batth, as McLean won a free-kick and crossed for the defender to poke home at the near post.
Striker Lee Gregory had a chance to put the hosts ahead but he fired over from close range from Powell's pass.
Substitute Kieffer Moore fired straight at Butland from distance while Marshall saved well from Ince in a frantic finish.
Substitute Diouf won it when he bundled in from close range to give O'Neill a second successive victory since taking charge.
No Data Analysis info