John Hubert ran for 166 yards and the go-ahead touchdown for the Wildcats (3-0). Collin Klein passed for two scores and ran for another for Kansas State, which blew an 11-point halftime lead before rallying.
Harris threw for 272 yards and two touchdowns for Miami (1-2), which got 106 yards and a touchdown from Lamar Miller. Miami had first-and-goal at the Kansas State 2 with 1:52 left, but a first-down pass fell incomplete, two Mike James runs were stopped and then Harris' knee was deemed down by replay officials after the on-field call was that he scored.
"We have no one to blame but ourselves," Miami coach Al Golden said.
It was the 145th time in the last 150 games where Kansas State won when leading at halftime, and the Wildcats earned this one.
Miller's 59-yard touchdown run with 2:52 left in the third quarter got Miami within 21-17, and Harris found Travis Benjamin with a 34-yard scoring pass 43 seconds into the fourth quarter to give Miami a three-point lead.
A short-lived lead, at that.
Bolstered by a 47-yard run by Hubert on third-and-1 - Miami was in something akin to goal-line defense, with just about everyone on the line of scrimmage 70 yards from its own end zone - Kansas State went 80 yards on eight plays. Hubert's burst from 2 yards out capped the drive, putting Miami in need of late heroics.
Harris almost delivered.
Buoyed along by 33-yard pass to Chase Ford, and a pass interference call against Kansas State's Nigel Malone in the end zone, the Hurricanes were 2 yards away from the win with four plays to get there. They wound up a few inches short.
``We have to execute,'' Golden said. ``That's on us. We didn't get it done.''
Klein finished with 93 yards rushing for Kansas State, which won despite being outgained 411-398. His arms bloodied from a few scrapes with the Florida Marlins' infield dirt, Klein completed 12 of 18 passes for 133 yards.
Harris completed 21 of 31 passes, and Benjamin caught six balls for 91 yards to lead Miami.
Klein set the tone on the first possession, leading K-State 63 yards on 11 plays and going in from 2 yards out to give the Wildcats a 7-3 lead with 5:57 left in the first quarter. He was a perfect 6-for-6 passing for 80 yards in the first quarter - against a Miami defense that in four quarters against Ohio State last week allowed four completed passes for 35 yards.
Klein connected with Tyler Lockett from 20 yards out with 13:28 left in the half, and the Wildcats were up 14-3.
Here's how good Klein was: When Kansas State seemed on the brink of trouble, his feet were more than enough to keep the Wildcats afloat.
``Their quarterback played exceptional,'' Golden said. ``Got to give Kansas State credit.''
The Wildcats committed penalties on four consecutive plays midway through the second quarter - holding on a completed pass, then two false starts sandwiched around a delay of game while Miami linebacker Sean Spence waved his arms to incite more noise from the decidedly less-than-full stadium. After John Hubert was stuffed on an option pitch, Kansas State faced 2nd-and-29 from its own 3.
Just when it seemed like Miami was ready to grab some momentum, Klein took over.
A 26-yard scamper while taking off from his own end zone on second down, followed by a 13-yard run on the next play, got Kansas State near midfield and averted disaster. Miami eventually forced a punt, but did nothing with the ensuing possession and went into the locker room down by 11 points.
A pair of false starts doomed Miami in the first quarter. The Hurricanes settled for a field goal on the game's opening drive when Jon Feliciano jumped early on third-and-1 from the Kansas State 17. And later in the period, Joel Figueroa - who had just entered the game after Brandon Washington limped off shaken up - moved early on a fourth-and-4 play where Harris had two open receivers and wound up forcing the Hurricanes to punt.
Those mistakes wound up costing Miami dearly in the end.