TORONTO -- It took a while for Phil Kessel to have a strong game against his former team.
"I'll take it," said Kessel, who was traded by Boston to Toronto in September 2009 for draft picks, including this year's No. 2 overall selection, Tyler Seguin. "That's a big one for us, a character win. Hopefully, we can get rolling now."
Kessel had only one assist in seven games against the Bruins since the trade. His fortunes changed on Saturday. He claimed that playing the Bruins wasn't different than facing other teams, but his teammates knew this one was important.
"I'm happy for him," Maple Leafs goalie Jean-Sebastien Giguere said. "Hopefully, this will give him some confidence. Phil's been working extremely hard, and the bounces haven't always gone his way. But it was a big goal for him."
Kris Versteeg scored the tying goal with just over 40 seconds left in regulation to set up Kessel's big shootout moment.
Carl Gunnarsson also scored for the Maple Leafs, who snapped a two-game losing streak.
Nathan Horton and Gregory Campbell had goals for the Bruins, which lost for the fourth time in 10 games.
Versteeg made it 2-2 with 42 seconds remaining with a power-play goal. A shot caromed off the end boards and bounced right to Versteeg, who shoveled the puck into the wide-open net.
"I kind of got lucky just being in the right spot and shoveled it in," said Versteeg, who has also run into tough luck on offense this season.
Rookie Nazem Kadri, on his first career attempt, also scored in the shootout for Toronto.
Seguin scored Boston's shootout goal.
Toronto started strong, skating hard and pressuring goalie Tim Thomas. But Tim Brent's giveaway in the Maple Leafs' zone led to Horton's ninth goal of the season at 4:48 of the first period. Horton snapped a shot high past Giguere.
After some uncharacteristic turnovers by the Bruins, the Leafs were rewarded with Gunnarsson's first goal of the season with 4:07 left in the first period.
Gunnarsson finished off a pretty pass through the crease from Tyler Bozak. Kadri got the second assist on the goal.
Kadri began the game centering the fourth line between tough guys Colton Orr and Jay Rosehill, who was called up from Toronto of the AHL on Friday.
Campbell beat Giguere from the high slot with a wrist shot through traffic at 6:08 of the third period to give Boston a 2-1 lead.
Giguere made 25 saves, playing well in his second game back from a groin injury.
"It's good to get the win, it shows that we can beat some good teams," Giguere said. "Boston is a really good team, especially on the road, but we need to put this in the bank and move on."
Thomas made 38 stops, including a number of big saves in the waning minutes before Versteeg's tying goal. He kept the Bruins in the game with a brilliant glove save on Francois Beauchemin in overtime.
"There's nothing else I could have done," Beauchemin said. "I looked up, it was an empty net and I shot it as hard as I could. His glove came up and saved it."
Thomas was so good he even got postgame praise from Toronto coach Ron Wilson.
"If not for Timmy Thomas there's certainly no way the game goes even to overtime or to a shootout, because he made some unbelievable saves," Wilson said. "He was huge."
Tomas Kaberle played his 844th game with the Maple Leafs, tying Darryl Sittler for eighth on the franchise list. ... Brett Lebda and John Mitchell were healthy scratches for the Maple Leafs. Daniel Paille and Jordan Caron sat out for the Bruins.