STANFORD -- Josh Scott had 17 points and 11 rebounds, Xavier Johnson scored 14 points and Colorado boosted its chances of a first-round bye in next week's Pac-12 Conference tournament with a 59-56 victory over Stanford on Wednesday night.
Xavier Talton added nine points and five rebounds to help the Buffaloes (21-9, 10-7 Pac-12) break a two-game losing skid and hand the Cardinal another setback. Stanford has lost three straight for the first time all season.
Chasson Randle scored 24 points to rally the Cardinal (18-11, 9-8) from an eight-point deficit to take the lead in the final minutes. But he missed a 3-pointer as time expired.
Both teams began the day tied with California for fourth place in Pac-12 play. The top four teams earn a first-round bye in next week's conference tournament in Las Vegas.
Colorado completes its regular-season slate Saturday at Cal. Stanford hosts Utah in its finale.
Josh Huestis had nine points and 13 rebounds and Dwight Powell added eight points for Stanford, which is trying to earn an NCAA tournament berth for the first time in six seasons under coach Johnny Dawkins. The Cardinal, who made the tournament in the 13 of 14 seasons prior, will likely need a strong run in Las Vegas next week for an at-large bid in the Big Dance now.
Stanford athletic director Bernard Muir said after last season that he expected Dawkins to take the team to the NCAA tournament. Dawkins has two more seasons remaining on his contract.
Even with the stakes high, there were chunks of empty seats throughout the arena. Former Stanford standouts and current NFL stars Andrew Luck and Richard Sherman tried to help fill the void, sitting together in the stands and, at times, drawing more attention from fans than the action on the court.
Neither team gave the fans who showed up much reason to cheer at the start. Both shot poorly and the game moved at a plodding pace until the closing minutes.
The Buffaloes outshot Stanford 38.8 percent to 36.8 percent and outrebounded them 39 to 31. Colorado made 17 of 25 free throws, while the Cardinal were 10 for 17.
After the Buffaloes built an eight-point lead late in the second half, Randle rallied Stanford in a hurry. He made three 3-pointers during a 13-2 run that lifted the Cardinal ahead 51-48 with 3:58 to play.
Colorado came back with a jumper by Xavier Johnson and 3-pointer by Talton. Randle answered just like he had before, starting a three-point play after getting fouled by Talton on a short jumper.
On the next possession, Askia Booker air-balled an open jumper as Colorado was called for a shot-clock violation. He atoned for his miss by stripping the ball from Randle and quickly getting fouled.
Booker made 1 of 2 free throws to give Colorado a 56-54 lead. Then Anthony Brown missed a 3-pointer, Scott corralled the rebound and hit two free throws with 13.1 seconds left.
After a timeout, Randle raced down court to convert an near-uncontested layup with 8.3 seconds remaining. Then Talton split two free throws to give Stanford one last chance.
Randle's pull-up 3-pointer glanced off the front of the rim as time expired.