This time, Greg Joseph was the hero.

The Vikings kicker drilled a 54-yard field goal on the final play to give them a 19-17 victory over Detroit on Sunday at U.S. Bank Stadium. And several teammates responded by carrying him off the field on their shoulders.

It was a far cry from Sept. 19, when Joseph missed a 37-yard field goal on the final play of the Vikings’ 34-33 loss at Arizona. After that game, teammates consoled Joseph in the locker room, and wide receiver Adam Thielen told Joseph he was confident he would get another chance to kick a big field goal.

That chance came three weeks later.

“I’m so happy for all the guys in the locker room,” Joseph said. “The team deserved that win, and happy I was able to deliver. … Personally, I don’t need to be carried off because they deserve as much credit as I do. … But it’s an awesome feeling. To hear that stadium erupt was pretty amazing.”

Newsletter signup for email alerts

Joseph rescued the Vikings from what could have been a devastating defeat after they blew a 16-6 lead in the final three minutes. Instead, they raised their record to 2-3 and the Lions remained winless at 0-5.

“That was tough,” said Detroit coach Dan Campbell, in tears after the game. “That was a heartbreaker.”

It looked as if the Vikings were about to add another heartbreaking defeat to their list this season, on top of losing the opener 27-24 at Cincinnati when Dalvin Cook lost a fumble late in overtime and the Bengals kicked a field goal, and then losing by one point at Arizona the following week.

With 1:56 left, Alexander Mattison, who rushed for a career-high 113 yards in relief of the injured Cook, lost a fumble at the Vikings 20.

The Lions, who cut the deficit to 16-9 with 2:30 remaining on Austin Siebert’s 40-yard field goal, wasted no time in taking the lead. D’Andre Swift scored on a 1-yard run with 37 seconds left, then Jared Goff threw a two-point conversion pass to KhaDarel Hodge to put them up 17-16.

Vikings linebacker Eric Kendricks didn’t deny he was thinking of some of the earlier losses this season when the Lions took the lead.

“Yeah, honestly, we’ve got to do better, obviously,” he said. “But we don’t want to be in that situation ever, especially when we’ve been playing well the whole game.”

The Vikings were able to salvage the win when Kirk Cousins threw completions of 21 yards to Thielen, six yards to Dede Westbrook and 19 yards to Thielen to get the ball to the Detroit 36. Cousins then spiked the ball, setting up Joseph’s field goal.

“It wasn’t the prettiest of wins, but it was a win, and we’ll take it,” Vikings coach Mike Zimmer said. “Sometimes when you win games like that, it’s a good thing because it evens out at some point if you can keep plugging along. … (Joseph) did a nice job, made a nice kick.”

Mattison was relieved when Joseph’s kick went through the uprights. He learned Sunday morning that once again he would start in place of Cook, who suffered a sprained right ankle against the Cardinals and missed his second game out of the past three.

Mattison also caught seven passes for 40 yards, and scored Minnesota’s only touchdown on a 15-yard reception in the second quarter when he bowled over several defenders inside the 5-yard line to put the Vikings up 13-3. But with the Vikings trying to run the clock down, Mattison was fighting for extra yards when he was stacked up on third-and-7 and had the bar jarred loose and recovered by Jalen Reeves-Maybin.

“It’s a play where you’ve got to know when the fight is over and forward momentum probably was stopped,” Mattison said. “But they didn’t blow the whistle. … It was a little bit of an emotional rollercoaster toward the end there but it’s football, and it happens to the best of us.”

After the fumble, Mattison said Cook told him, “I got your back.”

Minnesota also got a big game out of wide receiver Justin Jefferson, who caught seven passes for 124 yards. But there were periods during the game when the Vikings didn’t look much for Jefferson, and Thielen didn’t catch a single pass until the last drive.

The Vikings, a 10-point favorite, were content at times to be conservative on offense. The fans let them know their displeasure about that often during the game, including booing when the Vikings ran out the clock at the end of the first half when they started at their 19 with 41 seconds left and had two timeouts left.

Boos rained down after the Vikings blew the 10-point lead late in the game before they turned to cheers after Joseph’s winning kick. But there was still concern after the game about the Vikings barely defeating one of the NFL’s worst teams and scoring just one touchdown in each of the past two games.

“Always good to get a win,” said Cousins, who completed 25 of 34 passes for 275 yards but threw an interception for the second straight game after none in the first three games. “There’s certainly a lot that we can improve upon as a team.”

At least the kicker wasn’t an issue this time. Joseph made two 38-yard field goals in the first half, when the Vikings took a 13-6 lead, and he hit a career-long 55-yarder with 4:28 left in the game for a 16-9 lead. Joseph missed a 49-yarder short with 3:17 left but then made the one at the end that really counted.

“We knew that he was going to get another opportunity, and we’re thankful he’s on our team,” Thielen said.