ELMONT, N.Y. -- MacKenzie Weegar scored his first NHL hat trick for the Calgary Flames in their fourth straight win, 5-2 against the New York Islanders at UBS Arena on Saturday.

It was the first hat trick by an NHL defenseman this season.

“I never would have thought I’d have a hat trick in the NHL,” Weegar said. “Credit to my teammates, of course. We’ve just been playing great hockey. I’m sure, back home, everybody’s having some fun with it.”

Jonathan Huberdeau and Blake Coleman each had a goal and an assist, and Jacob Markstrom made 35 saves and had an assist for the Flames (25-22-5), who wrap up a four-game road trip Monday at the New York Rangers.

“I think for a while now, obviously the work ethic and just rolling four lines and three [defense] pairs [has been key],” Markstrom said. “The power play got us one today, and the penalty kill is really good. So, it was a good overall game.

“As a group, we need everyone to be going to be successful.”

Brock Nelson and Jean-Gabriel Pageau scored for the Islanders (22-18-12), who were 2-0-1 in their previous three games. Semyon Varlamov made 19 saves.

“I really hate to lose, especially in our building,” New York coach Patrick Roy said. “I feel like we need to be a little more dominant at home than what we did.”

Weegar gave the Flames a 1-0 lead at 3:47 of the first period on its second shot of the game, a wrist shot from the right face-off dot off the rush that got under Varlamov’s blocker.

CGY@NYI: Weegar fuels Flames' win with first career hat trick

Markstrom had the primary assist on the goal.

Kyle Palmieri thought he tied it for the Islanders at 13:59, but the Flames successfully challenged that Pierre Engvall preceded the puck into the offensive zone.

Huberdeau made it 2-0 on the power play at 8:38 of the second period, scoring on a rebound after Varlamov stopped a Noah Hanifin one-timer.

Weegar’s second of the game at 15:16 extended the lead to 3-0. After Walker Duehr whiffed from the low slot, the puck went right to Weegar, who one-timed it past Varlamov’s blocker.

“He’s unbelievable,” Huberdeau said of Weegar. “He was just rewarded tonight, getting his first hat trick. Head down, shoot the puck and it’s going in this year, so it’s nice.

“… He doesn’t get the opportunity to get a hat trick every game, so I’m really happy for him. He worked hard his whole life for it.”

Nelson cut it to 3-1 at 4:00 of the third period when his wrist shot from the high slot beat a screened Markstrom over the glove.

“It’s tough. I think it wasn’t our best,” Nelson said. “I wouldn’t say it was horrible, but for some reason we have found ourselves not really generating much possession and offensive zone time that we maybe had the last couple of weeks. Early, we found ourselves in a hole, and a little too late in the third when we started to find it.”

Coleman scored an empty-net goal at 15:59 to make it 4-1, but Pageau cut it to 4-2 at 17:28 after a scramble in front.

Weegar completed the hat trick with an empty-net goal at 19:38 for the 5-2 final.

“Until probably the last seven or eight minutes of the third period, I thought that was a pretty complete game for us again, similar to what we saw in Boston (4-1 win on Tuesday),” Calgary coach Ryan Huska said. “And we had all sorts of contributions from people, so that’s something that was important too."

NOTES: The previous hat trick by an NHL defenseman was from Nikita Zadorov, also for the Flames, in a 3-1 win against the San Jose Sharks on Apr. 12, 2023. … Markstrom has four assists this season; Mike Vernon had seven twice for Calgary (1987-88, 1991-92). … Flames defenseman Chris Tanev blocked five shots in 23:33 of ice time. ... Varlamov played his 600th NHL game. … Noah Dobson got his 47th assist of the season on Nelson’s goal, the most by an Islanders defenseman since Vladimir Malakhov in 1993-94. Malakhov finished that season with 47. … New York defenseman Alexander Romanov missed the game because of a lower-body injury. He is day to day. … Islanders forwards Mathew Barzal, Bo Horvat and Anders Lee were each minus-3. … Palmieri had eight shots on goal, and Barzal had seven.