Pacioretty assisted on Andrei Kostitsyn's goal 10:26 into the second and scored 2:12 later to make it 3-1. He added his second goal of the game in the third.
Yannick Weber scored a power-play goal late in the first period to tie it at 1. Michael Cammalleri also scored for Montreal, which got its first win in six games at the Bell Centre (1-3-2).
The Canadiens, who are 2-5-2 overall, had not gone this deep into a season before claiming their second win since 1941-42, when they got off to a 1-10-1 start.
Jaromir Jagr scored his third goal in two games for Philadelphia, which played its first game without injured captain Chris Pronger. Ilya Bryzgalov made 23 saves.
Canadiens assistant coach Perry Pearn was fired before the game. GM Pierre Gauthier told his players the news in the team's dressing room a few hours before the pregame warmup.
The Canadiens failed to score on their first opportunity after Philadelphia was called for too many men 58 seconds in.
Jagr soured the sold-out Bell Centre crowd's somber mood further when he put the Flyers up 1-0 at 10:43 on a goal sealed with his trademark salute.
Weber sent a jolt of energy through the building with 2.6 seconds left in the first when he drove a point shot inside the left post for his second goal and Montreal's fourth power-play goal of the season.
Kostitsyn got credit for putting the Canadiens up 2-1 midway through the second. Daniel Briere's clearing attempt went in off Kostitsyn's right skate, prompting a video review that upheld the goal.
Pacioretty, who left Monday night's 2-1 loss to Florida late in the second with an upper-body injury, made it a two-goal lead at 12:38 when a redirected puck left him a shot at an open right side for his third goal.
He made it 4-1 with his second goal of the game - his fourth of the season - 3:16 into the third. Cammalleri increased the lead to four with his third goal at 15:36.
Pronger is on bedrest and expected to miss two to three weeks after suffering an eye injury in Monday night's 4-2 win over Toronto.
Pronger, who does not wear a visor, was struck on the outside of his right eye by Maple Leafs center Mikhail Grabovski's stick blade.
NOTES: Flyers C Sean Couturier played his ninth game and GM Paul Holmgren will now have to decide whether he will remain with the team or be returned to his junior team. Couturier, who has two goals and two assists, was selected eighth overall by Philadelphia in the June draft. ... Flyers coach Peter Laviolette used his timeout 4:29 into the second. ... Price, who is 100-80-26 overall, was rested for the first time this season Monday. He had failed in five straight attempts to get his milestone win following a 5-1 win in Winnipeg. ... The Canadiens went 1 for 5 on the power play