LINCOLN, Neb. -- Wisconsin couldn't finish the job Saturday night against No. 22 Nebraska.

The Badgers lost 30-27 after their 17-point lead evaporated in the second half as Nebraska quarterback Taylor Martinez guided four straight scoring drives against a tiring defense.

"This is the worst feeling ever," running back Montee Ball said. "We had it. We clearly had it. We were dominating the entire game until, well, the entire first half. We just have to play a four-quarter game. We have to keep our foot on the gas."

Martinez scored on a 38-yard run, threw a 10-yard TD pass to Kyler Reed and set up Brett Maher for the tying and go-ahead field goals. Maher's 41-yarder with 9:41 left gave the Huskers (4-1, 1-0) their first lead in the Big Ten opener.

Danny O'Brien, who replaced Joel Stave, tried to bring back the two-time defending Big Ten champion Badgers (3-2, 0-1) with less than three minutes to play. But Ball fumbled at midfield on a fourth-and-1, and Martinez took a knee three times to run out the last minute.

"Obviously it was a tale of two halves," Wisconsin coach Bret Bielema said. "You could feel that momentum switch in the second half and it was something our guys never really able to get back in their grasp."

Nebraska's comeback tied the second-largest comeback in program history, trailing only Nebraska's rally from a 21-point deficit in the third quarter last season against Ohio State.

Martinez ran for 107 yards and threw for 181 yards and two touchdowns. Stave passed for 214 yards and a touchdown.

Ball, coming back from a head injury last week, carried 32 times for 90 yards and three touchdowns.

Both teams wore eye-catching alternate uniforms, and the Huskers and their fans were juiced up for the game after Nebraska was beaten 48-17 in Madison last year.

Playing off the energy of the boisterous Memorial Stadium crowd, the Nebraska defense held the Badgers to 90 yards in the second half.

Martinez kept the Badgers' defense on the field way too long in the second half, and it showed as the Huskers picked up yards in big chunks.

The Badgers had threatened to break open the game after defensive end David Gilbert blew past Nebraska left tackle Brent Qvale on his way to sacking Martinez and knocking the ball loose on the Huskers' fourth play of the second half.

Chris Borland picked up the ball for his second fumble recovery of the night, and four plays later Ball ran in from the 2.

The Huskers then started the comeback.

Martinez scored from 38 yards, slipping through the line on a quarterback draw and outrunning Dezmen Southward to the left pylon.

The Huskers got a three-and-out after Ball, needing a yard for a first down, bounced backward off his offensive lineman and Sean Fisher wrestled him down.

Martinez then led the Huskers 75 yards in 10 plays to make it a three-point game after he hit tight end Reed with a 10-yard pass across the middle of the end zone.

With the crowd raising the decibel level with chants of "Go Big Red, Go Big Red," the Huskers forced another three-and-out.

Martinez moved the Huskers from the 37 to the Wisconsin 21, and Brett Maher's 38-yard field goal made it a tie game heading to the fourth quarter.

After yet another Wisconsin punt, the Huskers went from their 16 to the Wisconsin 24, and Maher hit a 41-yarder for the lead.

The question coming into the game was whether Stave would be poised in making his first road start in such a big game.

It turned out that the home team was the unsteady one early. Stave was just fine -- actually, better than fine in the first half.

"That was the loudest crowd I've ever played in front of but it didn't seem to be a factor," Stave said. "We were able to get the calls off in the huddle. I didn't think it played a huge factor."

The redshirt freshman threw a beautiful 54-yard pass to Jared Abbrederis on the game's second play, and three plays later Ball scored from the 2.

Wisconsin got the ball right back. Burkhead fumbled while running up the back of offensive lineman Spencer Long. The Badgers went 23 yards for a quick 14-0 lead, with Ball bulling his way into the end zone from the 1.

After a Nebraska field goal, Abbrederis leapt in front of cornerback Andrew Green to catch a 29-yard touchdown pass. It was a 17-point game after Jack Russell missed the extra point.

Martinez led a 12-play drive that cut Wisconsin's lead to 20-10, finishing it with a 3-yard play-action pass to Burkhead.

Copyright 2012 by The Associated Press. All rights reserved. Material may not be redistributed.

More From KSOO-AM / ESPN Sioux Falls