Leo Komarov's third-period goal meant a whole lot to the Toronto Maple Leafs forward even before it turned out to be the game-winner against the New York Rangers.

Komarov hadn't scored in his first 13 games back with the Maple Leafs. His first of the season, scored with 5:34 left in the game, was the difference in Toronto's 5-4 on Saturday night.

"It's still in your head when you got zero goals," Komarov said.

In his second stint with the Maple Leafs, the 27-year-old Komarov has already matched the nine points in 42 games he had in his rookie year.

"Coming here, getting an opportunity to play for us for 48 games, it was kind of like a baptismal," coach Randy Carlyle said. "It seems like he's a lot more confident with the puck right now."

Confidence and instinct helped Komarov create two goals.

On the penalty kill in the first period, he got in the passing lane to disrupt play and forced the puck up the ice before feeding Peter Holland for a short-handed goal.

"They just missed the pass there, and that was the only way I could do it," Komarov said of taking the puck from defenseman Matt Hunwick. "It was a lucky pass I gave to him."

The winning goal wasn't lucky.

Defenseman Jake Gardiner waited out the defense before getting the puck to Komarov, who fired it past backup goalie Cam Talbot.

"It's always nice to score," Komarov said. "But I know I'm not going to score that much. It feels great to see the puck go in, but I think the win feels much better."

Roman Polak also scored in the third period to lift the Maple Leafs into a 4-4 tie. Phil Kessel and Richard Panik added goals for Toronto, which squandered a 3-1 lead.

Jonathan Bernier made 31 saves.

Chris Kreider, Mats Zuccarello, Carl Hagelin and Rick Nash scored for New York, and Talbot stopped 26 shots.

The Maple Leafs will play at Ottawa on Sunday in the makeup of the game postponed on Oct. 22 because of the shootings on Parliament Hill.

After this back-and-forth affair, the Rangers weren't happy about the open ice they gave to the Maple Leafs.

"I think we caused our own problems," said center Derek Stepan, who was strong in making his season debut after missing time with a broken leg. "We put ourselves in tough spots managing the puck and the game."

Rangers coach Alain Vigneault took issue with what he considered a couple of questionable penalty calls, but didn't absolve his team of blame.

"We made some poor decisions that led to goals," Vigneault said. "This is the NHL. They've got a good team and they can score a lot of goals. You'd think four goals on the road is enough to win, but it wasn't enough."

Just 53 seconds into his season debut, Stepan beat Holland on a faceoff to give the Rangers possession. Zuccarello tipped Kevin Klein's shot from the point past Bernier to make it 1-0.

Penalties to New York's Conor Allen (roughing) and Carl Hagelin (hooking) put Toronto on a 5-on-3 power play for 1:38. It only took 36 seconds for James van Riemsdyk to find Kessel with a cross-crease pass for his eighth goal of the season at 8:27.

Komarov found Holland streaking toward the net for the goal at 15:11 to make it 2-1.

At 18:59, Panik scored on a rebound to give Toronto a two-goal lead. It was Panik's second goal in two games.

The Rangers cut it to 3-2 with 39.9 seconds left in the first when Kreider's shot went between Bernier's pads.

At 17:44 of the second, Stephane Robidas and Jake Gardiner combined for a bad-bounce blunder. Robidas' pass deflected off Gardiner's skate to Dominic Moore and then pinballed to Hagelin, who finished the golden opportunity for his 100th career point.

Nash took advantage of porous net-front coverage to put the Rangers ahead 4-3 at 4:33 of the third. It was Nash's 11th goal of the season, tying Anaheim's Corey Perry for the NHL lead.

It took only until 7:27 for the Leafs to get even again. With David Clarkson screening Talbot, Polak fired from the point for his second of the season.

Komarov's first at 14:26 capped off his impressive night. Gardiner waited out the defense and fed the puck to an open Komarov, who made it 5-4.

"A couple times in a matter of a couple shifts it seemed like we were going up and down the ice," Holland said. "At the end of the day we want to make sure that we're not giving up odd-man rushes like we did a couple times there."

With the two-point night, Komarov matched his career high in points (nine) in just the 14th game of the season.

NOTES: During the first period, Johnny Bower was honored on his 90th birthday. The Leafs legend received a framed print signed by players from both teams. ... Leafs forward Daniel Winnik was held out after falling headfirst Thursday night in Colorado. ... Morgan Rielly returned to the Leafs' lineup after being a healthy scratch against Colorado. He replaced Stuart Percy. ... Kessel played in his 600th NHL game. Clarkson appeared in his 500th.