NEW YORK (AP) No matter where they are in the standings, the New York Rangers were just happy to finally get a win.

Vladislav Namestnikov snapped a tie in the third period, and the Rangers beat the New Jersey Devils 4-2 on Saturday night to stop a six-game slide.

''We've got 14 games to go and you can feel it in that locker room, winning feels way better than losing.'' Rangers coach David Quinn said.

''Obviously our situation is what it is, but we want to win hockey games.''

New York (28-28-12) hadn't won since beating New Jersey in their previous meeting on Feb. 23. It is well off the pace in the wild-card race in the Eastern Conference.

Ryan Strome had two goals and an assist for the Rangers, and Libor Hajek scored his first NHL goal. Namestnikov also had two assists, and Henrik Lundqvist made 22 saves.

Quinn said after the game that Hajek has a separated shoulder. He didn't have a timeline for his return.

Damon Severson and Blake Coleman scored first-period goals for New Jersey, which has lost six in a row. Cory Schneider made 37 saves.

''Yeah, it's frustrating,'' Schneider said. ''Being up 2-0 after one, having a lead going into the third to lose in regulation is tough. My job is to be one better and I wasn't able to.''

The Devils carried a 2-1 lead into the third, but Hajek got a cross-ice pass from Strome and wristed a shot past Schneider on the glove side at 1:29.

Namestnikov then made it 3-2 when he scored his 10th of the season at 13:25 off a pass from Mika Zibanejad. Strome added an empty-netter.

''It's positive that we finally closed a game out,'' Namestnikov said. ''I thought we deserved better in those overtime losses against Washington and Tampa, but hockey goes that way sometimes and I'm just we got the two points tonight.''

Trailing 2-0 after the first, the Rangers controlled play for most of the second and got on the board late in the period.

Kevin Shattenkirk's shot from just inside the blue line was deflected by Strome, who scored his 12th at 18:22. The Rangers outshot the Devils 14-2 for the period, but Schneider was sharp for New Jersey.

''I thought the whole second period we were really good,'' Strome said. ''We did a good job in the second of our pushback. We weren't great in the first. We had a good second period and kind of took the game over.''

The Devils got off to a fast start.

First, Severson's shot from the right point got past Lundqvist for his 10th of the season 16:26 into the first. Then New Jersey ended its lengthy power-play drought when Coleman deflected Will Butcher's shot for his 19th of the season at 19:49. The Devils had come up empty on their previous 25 power plays.

NOTES: Devils F Travis Zajac reached 500 points with his first-period assist. He is the fourth player in franchise history to reach the mark. ... New Jersey, which is without several forwards because of injuries, recalled forwards Eric Tangradi and Brandon Gignac from Binghamton of the AHL. ... Rangers defenseman Marc Staal was scratched. ... The Rangers agreed to terms with goaltender Adam Huska on an entry-level contract. He appeared in 69 games in the past three seasons with UConn. Huska was a seventh-round selection in the 2015 draft.

UP NEXT

Devils: Continue their six-game trip Tuesday night at Calgary.

Rangers: Open four-game trip at Edmonton on Monday night.

---

More AP hockey: https://apnews.com/NHL and https://twitter.com/AP-Sports

Copyright 2019 by AP. Any commercial use or distribution without the express written consent of AP is strictly prohibited.