Auston Matthews scored his NHL-leading 21st goal of the season 59 seconds into overtime and the Toronto Maple Leafs beat the Winnipeg Jets 4-3 on Thursday night to snap a three-game losing streak.

Mitch Marner, William Nylander and Ilya Mikheyev scored in regulation to help Toronto regain the overall NHL lead at 19-7-2. Frederik Andersen made 23 saves, and Matthews and Marner each added an assist.

Nikolaj Ehlers had two goals and an assist, and Paul Stastny also scored for the Jets. Connor Hellebuyck made 33 saves.

Winnipeg Jets center Pierre-Luc Dubois (13) watches as a shot from teammate left wing Nikolaj Ehlers (27) beats Toronto Maple Leafs goaltender Frederik Andersen (31) for the first goal of the game during the first period of an NHL hockey game, Thursday, March 11, 2021 in Toronto. (Frank GunnThe Canadian Press via AP)

Winnipeg Jets center Pierre-Luc Dubois (13) watches as a shot from teammate left wing Nikolaj Ehlers (27) beats Toronto Maple Leafs goaltender Frederik Andersen (31) for the first goal of the game during the first period of an NHL hockey game, Thursday, March 11, 2021 in Toronto. (Frank GunnThe Canadian Press via AP)

Toronto got the winner at the end of a long shift when Matthews took a pass from Morgan Rielly and roofed a backhander to seal it.

The Jets, who beat the Maple Leafs 4-3 on Tuesday on the heels of a 7-1 blowout loss to the Montreal Canadiens, and Maple Leafs will complete the three-game set Saturday night back at Scotiabank Arena.

Mikheyev made it 3-2 with 7:31 left in regulation, but the Jets tied it with Hellebuyck on the bench for an extra attack when Ehlers found Stastny with 2:26 remaining.

Winnipeg Jets goaltender Connor Hellebuyck (37) makes a stop against the Toronto Maple Leafs during the first period of an NHL hockey game, Thursday, March 11, 2021 in Toronto. (Frank GunnThe Canadian Press via AP)

Winnipeg Jets goaltender Connor Hellebuyck (37) makes a stop against the Toronto Maple Leafs during the first period of an NHL hockey game, Thursday, March 11, 2021 in Toronto. (Frank GunnThe Canadian Press via AP)

Toronto Maple Leafs center Mitchell Marner (16) celebrates his goal against the Winnipeg Jets with teammates Zach Hyman (11) and Morgan Rielly (44) during the second period of an NHL hockey game, Thursday, March 11, 2021 in Toronto. (Frank GunnThe Canadian Press via AP)

Toronto Maple Leafs center Mitchell Marner (16) celebrates his goal against the Winnipeg Jets with teammates Zach Hyman (11) and Morgan Rielly (44) during the second period of an NHL hockey game, Thursday, March 11, 2021 in Toronto. (Frank GunnThe Canadian Press via AP)

Winnipeg Jets goaltender Connor Hellebuyck (37) stops Toronto Maple Leafs center William Nylander (88) during the second period of an NHL hockey game, Thursday, March 11, 2021 in Toronto. (Frank GunnThe Canadian Press via AP)

Winnipeg Jets goaltender Connor Hellebuyck (37) stops Toronto Maple Leafs center William Nylander (88) during the second period of an NHL hockey game, Thursday, March 11, 2021 in Toronto. (Frank GunnThe Canadian Press via AP)