Thornton teed up a blast from the top of the right circle that glanced off the timely positioned Stuart and flew into the net to give the Sharks the win at 1:13 of OT.
The win snapped San Jose's five-game losing streak and extended the Flames ongoing fizzle to four games.
Patrick Marleau scored a power play goal and assisted on Logan Couture's goal in regulation for San Jose. Alex Stalock had fairly quiet night in goal, stopping 11 of 13 shots, including just one Calgary try in overtime.
Reto Berra turned away 32-of-35 shots for the Flames. Kris Russell and Mike Cammalleri both scored in the third period to drive the game into overtime.
Celebrity Families of 2014 [PHOTOS]