GAINESVILLE, Fla. (AP) Receiver Dorian Baker leaped into the stands to celebrate with friends, family members and fans. Several teammates grabbed an oversized Kentucky flag and started waving it back and forth. Others posed for pictures with band members and cheerleaders.

Cornerback Derrick Baity emerged from the tunnel to watch, carrying his young son Champ.

No doubt, this was one for the ages.

Kentucky ended one of college football's longest losing streaks by upsetting No. 25 Florida 27-16 on Saturday night in the Swamp.

Terry Wilson accounted for three touchdowns, Benny Snell ran for 175 yards and the Wildcats beat the Gators for the first time since 1986. Kentucky hadn't won in Gainesville since 1979.

''There's no feeling like this,'' Snell said. ''When the game ended, it's what I had dreamed about. There's no better feeling anywhere.''

The 31-game streak was the fourth-longest in NCAA history in an uninterrupted series, behind Notre Dame over Navy (43 games, 1964-2006), Nebraska over Kansas (36, 1969-2004) and Oklahoma over Kansas State (32, 1937-68).

''To say this losing streak doesn't bother you would be a lie because I think it's an undue burden that these players inherit sometimes,'' Kentucky coach Mark Stoops said. ''They don't deserve that.''

The Wildcats had lost three of the last four meetings by six points or less, a strong indication they were closing the gap.

The streak probably should have ended sooner, too. Florida needed triple overtime to escape in 2014 and had to overcome a 13-point deficit in the fourth quarter last year in Lexington, a game in which the Gators scored twice because receivers were left uncovered.

Stoops' team did it again Saturday, but that was about all that went wrong for the Wildcats.

Kentucky outgained Florida 454-360 and finished with 303 yards rushing.

''The streak had nothing to do with tonight's game and it has nothing to do with next week's game,'' Florida coach Dan Mullen said. ''That's what happens in sports. It's a tough loss for us. We've got to find a way to get better and play next week.''

Mullen insisted one game ''never defines anything'' but couldn't guarantee that his team would learn from the setback.

''I don't know if the loss tonight will hurt or help moving forward,'' Mullen said. ''We're going to find out in how we react to it on Monday and how we react to it throughout the whole week in practice and how react to it and how we step onto the field next Saturday. It might hurt. We'll find out.''

Snell and Wilson staked Kentucky to an 11-point lead, running wild as the Cats controlled both lines of scrimmage.

Snell patiently waited for holes to open and averaged 6.5 yards a carry. Wilson added for 105 yards on the ground, including a 24-yard scoring run .

Wilson also completed 11 of 16 passes for 151 yards, with two TDs and an interception.

The victory was Stoops' first in six tries in the series, a signature conference win for sure. Stoops' biggest win: Upsetting rival and then-No. 11 Louisville in 2016.

For Florida and Mullen, it was a reality check after roughing up Charleston Southern 53-6 in the opener.

All the problems the Gators endured in last year's 4-7 season - inability to stop the run, indecision at quarterback and an inconsistent offensive line - were evident again.

''This loss won't define us,'' Florida left tackle Martez Ivey said.

THE TAKEAWAY

Kentucky could have been up big early had Wilson not had two first-half turnovers. The sophomore also had three turnovers in the first half in the opener, a 35-20 victory against Central Michigan. Against Florida, Wilson fumbled close to field-goal range and threw an interception near the goal line. He regrouped and rebounded from both, a sign or potential growth.

Florida could be in for another long year. Mullen thought he could depend on defense and a running game, but both let him down and looked like they could be issues moving forward.

POLL IMPLICATIONS

The Gators will have a short stay in the AP Top 25 .

ODD ENDING

Florida's Feleipe Franks connected with Freddie Swain for a 4-yard score with 3:43 remaining that made it 21-16. But Franks missed a wide-open receiver for the 2-point conversion.

Kentucky couldn't run out the clock, giving Florida one final shot. But Franks fumbled on a second-and-10 play the Gators thought was an incomplete pass. Davonte Robinson picked it up and returned it for a touchdown on the final play.

MISSED CALL?

Southeastern Conference officials ruled Evan McPherson's 36-yard field goal attempt was wide right. But replays showed the kick hooking and appearing to cross inside the upright. Instead of trimming the lead to 21-13, the Gators trailed by two scores heading into the final 15 minutes.

ANOTHER STREAK

The Gators lost their SEC opener for the first time since 2004, a 13-year streak that had been the longest in school history.

UP NEXT

Kentucky hosts Murray State of the Football Championship Subdivision next Saturday.

Florida hosts Colorado State in a somewhat awkward matchup. The Gators will pay ex-coach Jim McElwain's former team $2 million for the trip. It was part of McElwain's buyout from the Rams.

---

More AP college football: https://apnews.com/tag/Collegefootball and https://twitter.com/AP-Top25

Copyright 2018 by AP. Any commercial use or distribution without the express written consent of AP is strictly prohibited.