BOULDER, Colo. (AP) Jared Baker ran for a career-high 207 yards and scored three touchdowns, powering Arizona past Colorado 38-31 Saturday night.

Baker scored untouched on runs of 79 and 45 yards and then was uncovered when he hauled in a 25-yard pass from Anu Solomon to break a 24-all tie in the fourth quarter.

That play capped a 94-yard drive and followed a 97-yard drive sparked by backup QB Jerrard Randall, who came in and reeled off three long runs himself before handing off to Baker, who tied it at 24 with his 45-yard run up the middle.

More from FoxSports

Randall again led the Wildcats (5-2, 2-2 Pac-12) out of the shadow of his own end zone but was shaken up on a 7-yard keeper to the Colorado 25. Solomon, who was ineffective over the second and third quarters, re-entered the game and found Baker wide open with 9:17 remaining for his third TD.

Randall ran 11 times for 81 yards and scored from a yard out with 4:40 left to make it 38-24, which proved the difference when Sefo Liufau found Shay Fields over the middle for a 30-yard touchdown with 2:19 remaining.

The Buffs (3-4, 0-3), who matched their school record with their 14th consecutive loss in league play, tried an onside kick but Arizona safety Will Parks recovered. They held on fourth down but Arizona downed the punt at the 6 and Colorado couldn't get very far with just 38 seconds to work with.

Baker, a senior, topped his career-high of 123 yards rushing set just last week in a rout of Oregon State. He averaged 9 yards on his 23 carries and also caught three passes for 40 yards.

Liufau led the Buffs on a 75-yard touchdown drive to start the second half and his 4-yard keeper broke a 17-all tie and gave Colorado its first lead, but the Buffs punted on their next five possessions.

The teams were tied at 17 following a first half that took an hour, 45 minutes even though two of the touchdown drives lasted 32 and 37 seconds, respectively.

The Buffaloes had to rely on a raw group of linebackers to slow down the Wildcats with Addison Gilliam (leg) and Kenneth Olugbode (leg) out. Last week, junior Ryan Severson injured his right ankle in his first career start, leaving the task Saturday night to freshmen Rick Gamboa and Grant Watanabe.

Gamboa has started the last month in place of Gilliam, but this was Watanabe's first start, and he recorded a big sack of Solomon in the first half.

Baker burst through a big hole, shot past a surprised secondary and outran defenders for a 79-yard touchdown that gave Arizona a quick 10-0 lead less than five minutes in. But the Buffs replied with a 72-yard touchdown strike from Liufau to Fields moments later to keep it close.

Liufau was 27 of 42 for 340 yards, two TDs and no interceptions. Solomon was 22 of 37 for 283 yards, two TDs and no interceptions and Randall completed all three of his throws for 42 yards.

---

Follow AP Pro Football Writer Arnie Melendrez Stapleton on Twitter: http://twitter.com/arniestapleton