Toronto failed to move up in the Eastern Conference race and remains in 11th place, two points behind Carolina for the eighth and final playoff spot.
"Wow, what do you say," the Maple Leafs captain said after Buffalo's second win this season when down three goals in the final period. "That's a heartbreaker to lose a game like that."
The comeback was Buffalo's ninth this season when trailing by two or more goals.
"It was amazing," said Sabres forward Jason Pominville, who tied the game with just over six minutes left when he beat goalie Andrew Raycroft with a wrist shot on a partial breakaway. "It was a great game to be a part of."
That is, as long as you wore a Sabres uniform.
"There's not much to say," said Sundin, who was stopped by goalie Ryan Miller with 14 seconds left in regulation in his bid to tie the game.
The win gave Buffalo 103 points, breaking a tie with Nashville for the top spot in the league.
Daniel Briere also scored for the Sabres, who have won four of their past five following a four-game losing streak.
"We've shown all year that we don't give up," Vanek said.
Toronto appeared to wrap up the game after Boyd Devereaux scored twice in a 3:52 span to start the third period to make it 4-1. After the goal, Miller threw his stick in disgust, a move that seemed to rally his team.
"I was ready to laugh more than anything," said Miller, who finished with 40 saves. "I felt pretty composed after that."
The Sabres stormed back, with Vanek starting the rally with his team-leading 37th at 5:27 to make it 4-2.
Twenty seconds later, Stafford put Buffalo ahead 5-4, re-directing Vanek's pass in front of Raycroft.
"It shows the character of the guys in the room," said Stafford, who has four goals in his past three games. "It shows how hard we want to work and how much we want this."
The teams wrap up their season series Saturday in Toronto, as the Maple Leafs continue to fight for a playoff spot. Carolina, Montreal, the New York Islanders and Toronto are separated by two points or less as they chase the final playoff spot in the East.
"We have to get a win for sure," Maple Leafs defenseman Ian White said.
Toronto did get a boost when defenseman Tomas Kaberle made his return after missing eight games with a concussion. Kaberle hasn't played since being checked into the boards on a late hit by New Jersey's Cam Janssen on March 2. He assisted on McCabe's goal.
Vanek opened the scoring 5:17 in with Buffalo on the power play.
McCabe tied it on a two-man advantage with 65 seconds left in the first on a slap shot from the top of the right circle.
The Sabres allowed a season-high 21 shots in the first period, but Miller kept them in the game with several sparkling saves, including a stop on Stajan's breakaway with five minutes left.
Stajan gave Toronto its first lead 4:11 into the second after re-directing Alex Steen's pass from the bottom edge of the right circle.
Raycroft finished with 29 saves.
Vanek has three goals and nine points in his five-game point streak. ... Buffalo defenseman Toni Lydman missed his fourth game because of an upper-body injury. ... Gill played in his 700th career NHL game. ... The Maple Leafs were 4-3-1 without Kaberle, the team's third-leading scorer. ... Toronto has lost four straight on the road.