They’re a tough group of individuals. They hung together. There was no way that they were going to back off. They knew they were close. We knew they were close and they just persevered.—Kyle Whittingham, Utah head football coach

SALT LAKE CITY — Utah’s 27-21 win over fifth-ranked Stanford on Saturday was followed by a jubilant postgame celebration on the field at Rice-Eccles Stadium. Fans rushed onto the turf to congratulate the players and coaches after the Utes’ first home win over a top 5 team in the history of the program.

“It’s definitely a great win. I think our whole team played great as a whole,” said Utah quarterback Travis Wilson. “We’re super excited and this is a great accomplishment for us. We’ve just got to keep building on this.”

The Utes (4-2, 1-2) received major contributions on offense, defense and special teams in bringing the nation’s second-longest active winning streak to an end at 13 games. Stanford (5-1, 3-1) had a chance to pull even or take the lead in the final minute, but wound up 6 yards shy of doing so — surrendering the ball on a loss of downs with only 47 seconds remaining.

Utah coach Kyle Whittingham said the difference was making two or three plays in crucial situations — something the Utes weren’t able to do in a 51-48 overtime loss to Oregon State or in a 34-27 setback to 12th-ranked UCLA.

“It all boils down to players and our players executed and did a great job,” said Whittingham, who considered it a team effort.

The game, he noted, pitted two physical football teams.

“We felt like that was a matchup that may work in our favor,” Whittingham said. “So many guys made plays tonight. So many guys to be proud of.”

Wilson and the offense generated 415 yards and 22 first downs. The sophomore completed 23 of 34 passes for 234 yards and two touchdowns. Running back Bubba Poole proved to be an effective weapon with a game-high 111 yards rushing and seven receptions. The offensive line also drew praise from Whittingham.

Kicker Andy Phillips maintained his season-long run of perfection by making two field goals and three PATs. His second-half kicks from 23 and 48 yards out proved to be the margin of the victory.

As for the defense, linebacker Trevor Reilly led the way with seven tackles and two fumble recoveries. Defensive end Nate Orchard also had a big game with two sacks and two forced fumbles.

Utah’s defense limited Stanford to only 13 first downs and forced two incompletions when the Cardinal had moved to the 6-yard line down the stretch.

Reilly noted that toughness has proved to be the team’s thing this year.

”I think that was personified there on the last stand,” he said.

The victory followed what Whittingham called an outstanding week of preparation.

“We did not have a bad practice, not even close to a bad practice,” he said in crediting the players for their hard work. “They put in the film time and that’s the reason why we won the game.”

Orchard agreed that the “preparation was great all week.”

There were other variables as well. On Thursday, Whittingham met with the senior class and made sure everyone was where they needed to be mentally. He said it was obvious they were — noting that the senior class refused to let the team get fragmented after the disappointing losses to Oregon State and UCLA.

“They’re a tough group of individuals. They hung together. There was no way that they were going to back off,” Whittingham said. “They knew they were close. We knew they were close and they just persevered.”

Whittingham was also confident that Wilson would bounce back from a six-interception performance against UCLA.

“We had the feeling he was going to come back and play like he did tonight,” Whittingham said. “He was able to put that one behind them.”

All in all, the Utes left the field quite happy. The reasons were plentiful. Whittingham acknowledged that it was very gratifying to get a win against a fifth-ranked team like Stanford that has been playing so well.

“I think we’ve proved that we can stand toe-to-toe with the teams in this conference — the quality teams in this conference, the upper-echelon teams in this conference — and slug it out,” said Whittingham, who called it a “good night” while adding how happy and proud he was for his players.

Wide receiver Dres Anderson expressed his gratitude for the fans who stormed the field after the game.

“It’s just great to see how much our fans love us and how everybody appreciates our hard work,” Anderson said.

Reilly considered it a little redemption for a 47-7 loss to fourth-ranked TCU at Rice-Eccles Stadium in 2010. He added that it feels great and noted that it was the team’s first big Pac-12 win.

As for the postgame gathering with fans on the turf, Reilly said he was “waving them on.”

After opening the season with five of six games at home and no trips outside the state of Utah, the Utes visit Arizona this Saturday and USC the following week.

“This win was very exciting,” Wilson said. “We’ve just got to keep building off this momentum.”

EXTRA POINTS: Utah has prevailed in 49 straight games when leading at halftime. ... Anderson had a team-high 82 yards receiving. ... Cornerback Davion Orphey was credited with two pass breakups. Safety Michael Walker had one. ... Tom Hackett averaged 44.6 yards on five punts, pinning three inside the 20. ... Mark Schlabach of ESPN.com is projecting a Utah-Wyoming matchup in the New Mexico Bowl. ... The Pac-12 Networks is re-airing the Utah-Stanford game Tuesday at 6 p.m. A 60-minute version can be seen Monday at 11 p.m.