The injury-riddled Panthers got just their fifth home win in 18 games (5-8-5) this season.
"I felt like there was a feeling on the bench that, you know what, we owed our fans here at home, we owed ourselves," Panthers coach Kevin Dineen said. "We didn't want to make it that entertaining but we'll take it."
Huberdeau tied the score at 4-all when he pushed the puck past Miller for a power-play goal with 6:09 remaining in the third period. It was Huberdeau's first goal in his past 10 games.
"It felt good," Huberdeau said. "As long as we win, I don't care if I don't score for 15 games."
Foligno's power-play goal with 8:27 to go in the third broke a 3-3 tie. Jordan Leopold's shot from the left circle was deflected by Foligno and got past Markstrom, but the Sabres couldn't hold the lead.
"We had a chance to just hunker down in the third and didn't do it," Miller said.
Matthias's put the Panthers up 1-0 at 3:28 of the first period. Miller blocked a shot but Matthias took the rebound in the slot and beat Miller on the stick side. It gave Matthias eight goals in his past 15 games.
"A couple of lucky bounces. I'll take it," Matthias said.
Fleischmann's power-play goal 43 seconds into the second period made it 2-0. He took a pass to the right of the crease and wristed the puck high into the net.
The Sabres made it 2-1 less than a minute later when Gerbe took a shot from above the right circle near the boards that deflected off a Panthers player and into the net at 1:36. Gerbe has four goals this season and three of them have come against the Panthers.
The Sabres scored twice late in the second to take a 3-2 lead.
Sekera grabbed a loose puck at the point and fired it past Markstrom with 5:04 remaining to tie the score. Christian Ehroff's shot from above the right circle was deflected by Stafford and bounced into the net with 56 seconds to go to put Buffalo ahead.
The Panthers tied it 3-all on Matthias's second goal as he got a rebound at the bottom of the left circle and his wrist shot got past Miller at 5:23 of the third.
"Obviously we didn't get the start we wanted, fell behind and kept composure and bounced back into the game, but again it's unfortunate to give up a lead," Pominville said. "Again, it's one of those one-goal games that we have to find a way to win."
Sabres F Thomas Vanek was scratched from Thursday's game with an upper-body injury he suffered in Tuesday's game at Tampa Bay. ... Sabres C Steve Ott played his 600th NHL game. ... Panthers D Ed Jovanovski will have hip surgery on April 5th. Jovanovski has only played six games this season and has been on injured reserve since Feb. 1. ... Kopecky has 16 points in his last 22 games.
Copyright by STATS LLC and The Associated Press
SUNRISE, FL - MARCH 28: Mike Weber #6 of the Buffalo Sabres checks Shawn Matthias #18 of the Florida Panthers at...
(Photo by Eliot J. Schechter/NHLI via Getty Images)