ANN ARBOR, Mich. — Michigan is off to a wobbly start this season and Army almost took advantage.

Jake Moody made a 43-yard field goal and the seventh-ranked Wolverines forced and recovered a fumble to hold on for a 24-21 double-overtime win over the Black Knights on Saturday.

The Wolverines (2-0) didn’t lead until the second extra period and would have lost at the end of regulation to the Black Knights (1-1) if Cole Talley made a 50-yard kick that was just short and to the right.

“The entire football game we made mistakes offensively — penalties, and turnovers, and turnovers on downs,” Michigan coach Jim Harbaugh said. “The defense was not in the best positions, but they played great.”

It marked the second straight year the U.S. Military Academy nearly beat a top 10 team for the first time in more than a half century. The Black Knights pushed No. 5 Oklahoma into overtime on the road last year before losing 28-21.

“Those guys aren’t in there, ‘Oh, shucks’ and, ‘Isn’t that great, we gave them a good game?'” Army coach Jeff Monken said. “They’re heartbroken because they believed they were going to win that game.”

Army had won 10 straight, a run that college football’s winningest program barely stopped.

In overtime at the quiet Big House, Black Knights quarterback Kelvin Hopkins ran for a go-ahead, 6-yard touchdown and Michigan extended the game with Zach Charbonnet’s third TD. Hopkins was sacked and lost a fumble to end the game in the second overtime.

Aidan Hutchinson hit Hopkins to jar the ball loose and Kwity Paye recovered the fumble to seal the win.

“At that moment, I knew it was game,” Hutchinson said, still holding the final football used in the game about 30 minutes after it ended.

Michigan turned the ball over on downs twice in the fourth, including early in the quarter when Harbaugh could have chosen to kick a go-ahead, 36-yard field goal.

The Black Knights appeared to have the stronger and smarter team for much of the afternoon, running its triple option offense effectively and making fewer miscues.

“We just came here and took them to overtime with a bunch of guys that, frankly, nobody at this level recruited,” Monken said.

Army’s Sandon McCoy scored on a 1-yard TD in the opening quarter after Patterson lost a fumble on his first drive. The Wolverines answered with Charbonnet’s 2-yard touchdown on the ensuing possession to pull into a 7-all tie, a drive they kept alive with a fake punt. On the trick play on a fourth-and-10 from the Michigan 42, a short snap went to Michael Barrett and he threw a 25-yard pass to Dax Hill to pick up a desperately needed first down.

Harbaugh said he would’ve elected to punt if Delvin Gil was not called for a false start, which allowed him to see Army’s punt coverage that included a cornerback rushing for a block.

“They jumped offside and they saw it,” Monken said. “They must’ve checked to it, thrown it out there.”

Michigan running back Ben VanSumeren lost a fumble and the Black Knights took advantage, going ahead on Hopkins’ 1-yard TD run late in the second.

Hopkins threw an ill-advised pass on third-and-5 from the Michigan 5 and Lavert Hill intercepted it early in the third quarter. Michigan made the most of the opportunity with the ball, capping a 12-play drive with Charbonnet’s 1-yard TD run and pulled into a 14-all tie.

The No. 7 Wolverines escaped Saturday with a 24-21 double-overtime win over unranked Army in Ann Arbor, Mich.

Army had a chance to pull off what would have been college football’s first massive upset of the season, but freshman kicker Cole Talley missed a 50-yard field goal with two seconds remaining in regulation.

Army struck first in overtime with a touchdown, but Michigan countered and then made a field goal before stifling the Black Knights’ next possession with a game-winning fumble.