Terry Tarpey hit two free throws with 2:28 left to give the Tribe a 71-70 lead - its first since it was 9-8 - after trailing by as many as 22 in the first half.
Tarpey made the second free throw of a one-and-one with 25 seconds left to give William & Mary a 74-72 lead. UNCW's Jordon Talley missed a 3-pointer with 14 seconds left and Thornton sealed it with two free throws.
Omar Prewitt had 16 and Tarpey added 13 for William & Mary (10-6, 4-1 Colonial Athletic Association).
The Tribe started the second half on a 14-4 run.
Addison Spruill made 5 of 6 3-pointers and finished with a career-high 33 points for UNC Wilmington (8-8, 3-2). The senior's previous high was 20.