Fredette, the nation's leading scorer, made just 7-of-21 shots from the field and committed an offensive foul with 2:55 to play and his team clinging to a two-point lead.
The Cougars were still in front by one with 48 seconds to go when Fredette scored on a layup while being fouled by Amath M'Baye. The ensuing free throw put BYU in front 64-60 and the Cougars held on to improve their season record to 21-2.
BYU is tied for the lead in the Mountain West Conference at 7-1 with San Diego State, which edged Colorado State 56-54 Wednesday. The Cougars were playing for the first time since a surprising loss to New Mexico Saturday.
Fredette finished with 26 points and Brandon Davies had 20. Davies also had a 3-point play in the final minute to protect the BYU lead.
Desmar Jackson had 23 points to lead Wyoming (8-14, 1-7). The Cowboys have lost six straight.
Celebrity Families of 2014 [PHOTOS]