Gridin made it 3-1 at 7:49 when he tapped in a pass from Farabee into an open net to finish a short 2-on-1 rush.
“Pushing a little too hard, maybe, trying to get those grade A chances, and then we leave such a hole in the defense," Carlsson said. "Just too many breakways.”
Frost increased the lead to 4-1, sliding a wrist shot five-hole while on a breakaway at 18:44 for his 20th of the season.
"I hope one day I can score 30, but 20 is very cool for me," Frost said. "Definitely not something I would do, so I'll build for the next milestone."
Carlsson cut the deficit to 4-2 at 7:49 of the third period. Calgary defenseman Zach Whitecloud deflected Carlsson's attempted centering pass back to him, and he roofed the puck over a sprawling Cooley from in front.
McTavish brought the Ducks to within 4-3 with a power-play goal at 9:51. He collected Alex Killorn's pass from below the goal line, skated into the right circle and buried a snap shot that went in off Cooley's left shoulder.
Anaheim has six wins this season after trailing in the final two minutes of a game, the most in NHL history, but it wasn't able to get the tying goal with Husso pulled for the extra skater.
"We got going in the third with some possession and zone time and opportunities," Ducks coach Joel Quenneville said. "We've been fortunate (to come back) all year, tonight it didn't happen."
Frost secured the 5-3 final with an empty-net goal at 18:49.
"The first 10 minutes of the third period, we were pretty locked down," Frost said. "We knew they were going to come, it was a big game for them. We found a way to win in the third, so happy for the effort."
NOTES: The Flames extended their point streak against the Ducks to nine games (5-0-4). ... Strome has 11 points (five goals, six assists) in 15 games with Calgary after producing nine points (three goals, six assists) in 33 games with the Ducks this season. ... Sennecke leads NHL rookies with 23 goals. He also tied Trevor Zegras (23 in 2021-22) for the third-highest single-season goal total by a rookie in franchise history. Only Bobby Ryan (31 in 2008-09) and Dustin Penner (29 in 2006-07) have more. ... Carlsson has 12 points (six goals, six assists) in his past 11 games. ... Sennecke (58 points; 23 goals, 35 assists) passed Ryan (57 in 2008-09) for the second-most points in a season by a Ducks rookie. Zegras holds the franchise mark (61 in 2021-22). ... Anaheim defenseman Tyson Hinds made his NHL debut after being recalled from San Diego of the American Hockey League earlier in the day. He had four shots on goal and one block in 23:22 of ice time.