NEW YORK — He was the last one into the visiting locker room at Madison Square Garden, late to the celebration he had set into motion with one of the biggest goals in Devils history.

Ryan Carter had TV and radio interviews. He had congratulations to accept after this 5-3 victory, with this franchise on the brink of a conference championship. He had to soak up his 15 minutes — quite reluctantly, it should be noted — before he could rejoin his teammates.

“Give me your gear before it’s stolen,” an equipment guy told him as he finally approached the locker room. “You’re going for five large now on eBay.”

Carter pulled his jersey over his head.

“Is my mom the highest bidder?” he cracked.

On this night, after this goal, Mrs. Carter would have stiff competition. About 15 minutes earlier, this is what unfolded on the Garden ice: Carter, whom the Devils claimed off waivers in October, took a pass from behind the net from Stephen Gionta, who had played in exactly one regular-season game in the NHL this season.

Carter banged the puck past Rangers goalie Henrik Lundqvist — a candidate for just about every major award this season — with less than five minutes left in the third period. He did this after the Devils’ own Hall of Fame goalie, Martin Brodeur, essentially kicked the game-tying goal into his own net and gave the Garden faithful a sense that victory was inevitable.

Yes, the whole thing was about 10 levels of crazy. Ryan Carter — Ryan Carter? — had saved the Devils from blowing a 3-0 lead. Ryan Carter — Ryan Carter?! — had put them one victory from playing for the Stanley Cup again.

He tried to deflect the credit. He pointed out that superstar Ilya Kovalchuk, extending his shift on the forecheck, had beaten the Rangers defense to the puck to start the play. He made it clear that the most important moment was the pass from Gionta, who also had the game’s first goal.

“All I had to do,” Carter said, “was redirect it.”

Still: Carter got the goal. Hockey history is littered with unlikely players scoring huge goals, and Carter added his name to the list. He was a fourth-line center fighting for minutes (or, in some cases, simply fighting) for most of the season. Now he’ll go down in franchise history if the Devils can close out this series.

Maybe, for the casual fans out there, a quick introduction is in order: Carter is a 6-foot-1 center from White Bear Lake, Minn., which is “a city of lakes and legends,” according to its website. It is no frozen outpost, despite the name.

“I know it sounds like it’s in Northern Minnesota,” he said, “but it’s actually just a (Minneapolis) suburb.”

He has climbed from the lowest level of the sport, playing for the Green Bay Gamblers of the USHL, to the highest, seeing his name etched on the Stanley Cup with Anaheim in 2007. He played for Devils coach Pete DeBoer in Florida, and when the Panthers waived him in late October, the Devils quickly claimed him.

It has not always been a glamorous career. He broke his wrist once in a freak accident when his arm got stuck in the photographer’s hole in the glass. His nose is shaped sort of crooked, like a stick, since it’s been broken so many times that he lost count a long time ago.

“Once it breaks, it breaks easy,” Carter said. “It’s almost like a fault line.”

He is the antithesis of a star, but that’s the beauty and mystery of the hockey playoffs. The Devils are one victory away from the Stanley Cup Finals, in large part, because of a ragtag line of grinders thrown together at the end of the regular season. Carter, Gionta and Steve Bernier have now accounted for eight goals in 17 playoff games, all of them at even strength and most of them at crucial times.

Patrik Elias said the Devils “stole one” after the Rangers spotted them a 3-0 lead and then dominated the game. They were the desperate team. They were the better team. When Brodeur misplayed that puck deep in his own zone — “It wasn’t the most fun few seconds,” he said — a Rangers victory seemed inevitable.

Instead, it was Carter who stepped onto the stage. Now the series goes back to New Jersey for Game 6, a chance for the Devils to clinch. They have had this chance before, of course, exactly 18 years ago. They failed, and the Rangers made history.

“Whatever is going to happen in the next few days,” Brodeur said, “is what our rivalry is going to be all about.”

For now, though, they are in this spot because of the most unlikely hero for the Devils. If that jersey really does end up on eBay, Mrs. Carter better hurry. There would be plenty of bidders.