Full-back Matty Bowen scored a late 65-metre try as Wigan fought back to beat a resurgent Catalan Dragons.
Morgan Escare grabbed the first points, starting and finishing a superb length-of-the-field try for the visitors.
Ben Pomeroy also touched down before Bowen went over for his first score to make it 10-4 at the break.
Converted Josh Charnley and Liam Farrell tries made it 16-16 after Escare crossed for his second, before Bowen sealed victory late on.
Victory extends Wigan's winning run to three games, but the Super League champions were made to work hard by a Dragons side that had only earned their first of the season against Huddersfield in their previous outing.
Escare collected Matty Smith's high ball that was misjudged by Mathias Pala, and the youngster linked up with Leon Pryce and Louis Anderson before finishing a remarkable opening try.
Pryce was again involved as Pomeroy powered over to make it 10-0, with Thomas Bosc unsuccessful with his second conversion attempt.
Bowen hit back after a period of good pressure by the hosts, throwing a series of dummies before forcing his way over.
The Australian, however, was to blame for letting Escare add to the French side's advantage after the break, spilling a Pryce kick.
Smith and Sean O'Loughlin, who was back to lead Wigan after three weeks out with a shoulder problem, combined to send winger Charnley over at the corner, giving Wigan hope.
Joe Burgess and Charnley had efforts disallowed, before Farrell collected a short offload from Smith to go over.
Smith added the extras to level things at 16-16, but then missed a penalty trying to put the home side ahead for the first time on 73 minutes.
Michael Oldfield managed to stop Burgess from grabbing a late winner, only for Bowen to safely pick up a chip over the top from Escare and then race clear for the winner.
Wigan coach Shaun Wane:
"He [Bowen] had a quiet game by his standards but to come up with that at the end was outstanding.
"That is what he has been doing for years.
"We bombed a few tries and it could have easily been a 20-point win, but fair play to them, they came here and had a dig.
"They are a tough team to beat, as we saw against Huddersfield last week. We weren't at our best but we have found a way to win, so I am satisfied with that."
Catalan Dragons coach Laurent Frayssinous:
"I thought we deserved a point for the effort made by the guys, but rugby league is a tough and cruel sport and our discipline wasn't good enough in the end to win the game.
"The performance as a team was very good. Against St Helens we started to build something and we showed it last week, and now we need to be a little bit consistent and we are confident for the future.
"The defeat hurts. We want to win every game. There are a lot of positives from tonight and I am pretty happy, but we need to do it consistently."
Wigan Warriors: Bowen; Charnley, Goulding, Thornley, Burgess; Green, Smith; Taylor, Tomkins, Flower, L. Farrell, Bateman, O'Loughlin.
Replacements: Crosby, Pettybourne, Clubb, Williams.
Catalan Dragons: Escare; Oldfield, Pomeroy, Millard, Pala; Pryce, Bosc; Elima, Pelissier, Bousquet, Taia, Anderson, Mounis.
Replacements: Maria, Paea, Baile, Garcia.
Referee: Tim Roby