It's not quite David vs. Goliath, but it was as close as you will find in Minnesota high school football.

Totino-Grace, a school of 740 students, pulled off the upset of the year, ending the 40-game, four-state championship run of Eden Prairie (enrollment 2,777) with a 27-13 thumping of the Eagles in the Class 6A quarterfinals Friday at Osseo High School.

"I think it's historic," Totino-Grace coach Jeff Ferguson said. "We're opting up not one but two classes. It's a leap of faith. This is one of the great accomplishments in recent high school sports history."

Considering the history between these two programs and Eden Prairie's dominance this season, Ferguson can be excused for embellishing a bit.

Totino-Grace had lost five consecutive games to Eden Prairie before Friday, three times in the playoffs. Totino-Grace nearly beat Eden Prairie in last year's Prep Bowl but lost on a failed two-point conversion attempt.

The losses, including in this year's season opener in August, had piled up. But they had also had the effect of familiarizing each other. Eden Prairie's reputation often precedes it and can intimidate opponents. Totino-Grace knew Eden Prairie well. The Fridley-based Eagles knew they could be successful. Fear never entered their minds.

"Our coaches do a great job of preparing us," said senior linebacker Charlie Waters, who had two second-half interceptions. "They tell us from the first step we take on the track to believe in ourselves. We believed we could win."

Outside of Totino-Grace (9-2), few others did. When Eden Prairie took a quick 7-0 lead after a botched punt snap, it looked as if coach Mike Grant's team was headed for another victory.

But the Totino-Grace defense stood toe-to-toe with Eden Prairie all game. It kept Eden Prairie off the scoreboard for the rest of the first half while its offense slowly pounded away, chipping off a piece here and there, setting the stage for a 27-point second-half onslaught, including the go-ahead 2-yard TD run by Gayflor Flomo in the fourth quarter.

Totino-Grace will face Osseo in the Class 6A semifinals at 7 p.m. Thursday at Minnetonka.

"In the locker room, the coaches kept saying that we could win this game," said Totino-Grace running back Ivan Burlak, who rushed for two touchdowns and, combined with backfield mate Flomo, spent most of the second half running through the vaunted defense of Eden Prairie (10-1).

The Totino-Grace grit clearly rattled Eden Prairie. Its defense was called for four personal fouls in the second half. On Totino-Grace's drive that tied the score 13-13 via an 11-yard touchdown catch by Alec Spevacek, Eden Prairie committed 45 yards worth of penalties.

"I don't know what was going on there. We gave them a touchdown," Grant said. "Our defense played well, it really did. But that's a good football team over there. Give them all the credit."