Williams had missed a three-pointer seconds earlier but the Jazz corralled an offensive rebound and he got another chance.
Williams ran down the clock, pulled up a few feet behind the three-point line and sank the basket to end the game and send the crowd into a frenzy.
It was Utah's (13-10) fourth straight win and snapped a five-game win streak for the Spurs (18-5).
Utah's Paul Millsap finished with 24 points and 12 rebounds while Al Jefferson chipped in with 21.
The Jazz had trailed by eight with a little more than four minutes remaining but battled back to tie the game and snatch victory with the final shot.
Tony Parker and Tim Duncan had 22 points apiece for San Antonio with Duncan also adding a season-high 21 rebounds. (Writing by Jahmal Corner in Los Angeles; Editing by Peter Rutherford)
- Sports & Recreation
- Paul Millsap