Franco di Santo's late strike moved Wigan off the bottom of the Premier League and heaped pressure on Sunderland manager Steve Bruce.
Wes Brown messed up a Keiren Westwood clearance in stoppage time and James McArthur nipped in before setting up Di Santo - who slotted into an empty goal.
Sunderland have only won once in 10 but they went ahead as Sebastian Larsson pounced on Ali Al Habsi's error.
Jordi Gomez equalised with a penalty before Di Santo nicked the win late on.
It was Wigan's first away win of the season - and only their second overall - but they are now within two points of Sunderland and escaping the relegation zone.
Wigan went into the game low on confidence with just one win from their previous 12 encounters and their spirits took a further hammering when they went behind after eight minutes.
Sunderland have hardly been high in belief either with just one league victory at the Stadium of Light this season before Wigan's visit but the return of Larsson from suspension inspired them.
Sunderland's top-scorer pounced when Al Habsi fumbled Bendtner's rather tame shot into the path of Kieran Richardson.
The Latics keeper did manage to close Richardson down but the ball spun to Larsson and he smashed home his fourth of the campaign in Sunderland colours.
Al Habsi was called upon to save from Richardson and the visiting keeper went some way to making up for his earlier error when he denied Brown's header after the defender rose to head Larsson's resulting corner.
Did you know?
- Sunderland have only won one of their last nine home games since beating Wigan 4-2, and managed a mere 10 points out of a possible 45.
Wigan manager Roberto Martinez was probably preparing a stern talking to for his charges until Victor Moses was tackled in the penalty area by Larsson and, despite the Swedish midfielder's protests, referee Kevin Friend pointed to the spot.
Gomez calmly stepped up to send Westwood in the wrong direction and grab his second goal of the season.
After a frantic opening half for the hosts, their pace dramatically slowed down after the break but Richardson did have a glorious chance with 10 minutes remaining.
Jack Colback burst down the left before crossing for the former Manchester United midfielder but he headed wide from close range.
The late drama came deep into stoppage time, however, as Brown played a ball back to Westwood.
The Sunderland keeper lobbed the ball back to his defender but it came off his knee and McArthur was alert to dispossess Brown.
He played the ball across the area to fellow substitute Di Santo who, with Westwood out of position, had the simplest of finishes as he slid the ball into an empty net.
The win - Wigan's first since they overcame QPR in August - is timely ahead of matches against Arsenal, Chelsea, Liverpool and Manchester United in four of their next five outings.
Sorry, we were unable to load match stats, please try again.