Williams, who scored 10 points, hit the game-winner after teammate Richie Gordon missed a layup with 5 seconds left and Harouna Mutombo grabbed the rebound. Western Carolina (8-10, 4-2 Southern Conference) has won four consecutive games.
The game featured 11 ties and 17 lead changes.
Appalachian State's Omar Carter hit a free throw for a 76-75 lead, but Brandon Boggs gave the Catamounts a 77-76 lead with 2:32 to play.
The Mountaineers (7-9, 3-3) retook the lead on Marcus Wright's jumper with 1:54 left.
Trey Sumler scored 17 points, Gordon had 16 and nine rebounds, Mutombo scored 12 and Boggs had 10 for Western Carolina.
Carter scored 19, Donald Sims had 18, Andre Williamson added 14 and Wright scored 10 for the Mountaineers.