The setback dropped Anaheim to 23-18-9 (55 points), fifth in the Pacific Division by point percentage (.550).
Calgary has won eight straight games, the longest active streak in the NHL, and leads the Pacific Division in points (62) and point percentage (.660).
John Gibson made 16 saves in his 35th start of the season. Anthony Stolarz stopped 21-of-22 shots in 31 minutes of relief.
Sonny Milano and Isac Lundestrom scored for Anaheim.
The Ducks seventh-ranked power play could not solve the Flames' third-ranked penalty kill, going 0-5 on the man advantage.
Calgary jumped out to an early lead on home ice, much as it has all year long. The Flames have scored the game's opening goal in 31 of 47 games this season. Dillon Dube put the Flames ahead, tipping home a point shot by Rasmus Andersson after an Anaheim neutral zone turnover.
Elias Lindholm doubled the advantage on a fortutious bounce for the home side with seven minutes to go in the opening frame, a sharp angle trickler that snuck through Gibson's pads and just over the goal line.
Despite the two-goal deficit, the Ducks controlled the pace of play for much of the first period, applying consistent pressure in the offensive zone.
That pace appeared to continue into the middle stanza when Milano cut the deficit to one on an impressive move in tight, but two critical mistakes minutes later came back to cost the Ducks dearly.
Milano put the Ducks on the board, taking a pass along the blueline from Lundestrom before cutting to the net and beating Flames netminder Jacob Markstrom on the short side.