WEST LAFAYETTE, Ind. -- Kirk Cousins threw three touchdown passes, and Michigan State overcame an 11-point fourth-quarter deficit to beat Purdue 40-37 and become bowl eligible on Saturday.
B.J. Cunningham caught three passes for 92 yards and a score for the Spartans (6-5, 4-3 Big Ten).
Purdue quarterback Joey Elliott completed 39 of 55 passes for 373 yards and two touchdowns. Keith Smith caught 15 passes for 152 yards and a TD for the Boilermakers (4-7, 3-4), who were eliminated from bowl contention.
The Boilermakers gained 524 yards and kept the ball for 41 minutes, but Michigan State gained 229 yards on kickoff returns, and the Spartans stopped Purdue on its final possession.
Michigan State's Brett Swenson made four field goals, including the game-winning 21-yarder with 1:51 left.
Alamo Bowl representatives attended the game.
Ralph Bolden fumbled on Purdue's first offensive play, and Michigan State's Chris Rucker returned it 11 yards for a touchdown seven seconds into the game.
Purdue came right back and drove 80 yards to tie the score. Elliott found Smith over the middle, and Smith broke a tackle before finishing a 26-yard touchdown reception.
Purdue's Carson Wiggs made two field goals, but Michigan State bounced back quickly. A 55-yard pass from Cousins to Charlie Gantt set the Spartans up inside the Purdue 10, and Cousins completed a 4-yard touchdown pass to Andrew Hawken to give the Spartans a 14-13 lead early in the second quarter.
Purdue scored later in the quarter on a 9-yard run by Bolden, and the Boilermakers took a 20-14 lead. Bolden was given an unsportsmanlike conduct penalty for hugging mascot Purdue Pete after the run.
The Boilermakers led 20-17 at halftime. Purdue outgained Michigan State 266-174 before the break.
Swenson made a career-long 52-yard field goal to make it 20-all, but Purdue came back with an 18-play, 80-yard drive. Elliott capped it with a 3-yard TD pass to Cortez Smith to give the Boilermakers a 27-20 lead. It was Purdue's longest scoring drive of the season.
Swenson hit another 52-yarder late in the third quarter to cut Purdue's lead to 27-23.
Purdue's defense held, then the Boilermakers came back with another scoring drive. Bolden scored his second touchdown, a 1-yarder to make it 34-23 early in the fourth quarter.
Michigan State needed just one play to respond. Cousins found Cunningham for a 73-yard touchdown, and the Spartans cut Purdue's lead to 34-30.
A 50-yard field-goal attempt by Wiggs was blocked, and the Spartans gained possession at their 46-yard line. A run by Keshawn Martin on a reverse went for 45 yards and put the Spartans inside the Purdue 10. Cousins found Blair White for a 9-yard score with 6:59 to play, and Michigan State took a 37-34 lead.
Purdue drove into field-goal range again, and this time, Wiggs converted from 49 yards to tie the game at 37 with 2:38 to play.
Martin returned the kickoff 84 yards to the Purdue 11 to set up Swenson's game winner.
GameDay 100: LaVar Arrington shows off his incredible athleticism by perfectly timing his leap over the offensive line and tackling the opposing team's running back.
Ohio State scored its second ESPN 300 commitment this weekend in CB Amir Riep. Read below to see how Riep can work his way into the Buckeyes' young group at corner:What he brings: He has a tall frame, but appears slighter than his listed measurables.
Urban Meyer and his staff add yet another ESPN 300 defensive lineman to their No. 1-ranked 2017 recruiting class.
Jim McElwain and staff were able to flip the ESPN 300 player from North Carolina.
Coaches, teammates and friends take to Twitter to remember Sam Foltz and Mike Sadler, who died in a car crash while returning from a kicking camp.
Nebraska punter Sam Foltz and former Michigan State punter Mike Sadler were killed in a car wreck Saturday returning from a kicking camp in Wisconsin.