Updated

Marcus Thornton scored 21 points and made several big shots late to lead the Sacramento Kings rally to a 104-103 victory over the Golden State Warriors on Sunday night.

Thornton's jumper with 12.6 seconds remaining put the Kings ahead by four and sealed the victory, snapping Sacramento's two-game losing streak. The teams split the season series 2-2.

DeMarcus Cousins added 15 points and 13 rebounds, and Tyreke Evans and Jason Thompson each scored 14 points for the Kings, who overcame an eight-point deficit late in the fourth quarter.

Stephen Curry had 27 points and eight assists, and David Lee finished with 24 points and 14 rebounds for the Warriors, who had won three straight. Monta Ellis left in the final minutes with a head injury and did not return.

The Kings were sloppy for most of the game but delivered when it counted.

They erased the eight-point deficit in the fourth with an 11-0 run to take a 92-89 lead. Then Curry and seldom-used reserve Jeremy Lin answered with consecutive jumpers to put Golden State back in front.

Evans followed with a 3-pointer before Thornton's driving layup gave Sacramento a 97-93 lead with a little more than 3 minutes remaining. Golden State came back within one, and then Cousins was called for a shot-clock violation.

The Warriors spoiled a chance to take the lead on the next possession, with Beno Udrih intercepting an errant pass from Curry. Thortnon followed with a jumper to put the Kings ahead by three, and then the Kings delivered a knockout blow — even if it wasn't intentional.

Ellis was fouled hard by Cousins on a driving layup with 1:32 to play, falling head-first onto the floor. Ellis momentarily laid motionless and was so woozy when he stood up that teammates had to help him balance.

He was helped to the locker room and did not return, and the Warriors certainly could've used their star. Thornton came back with a jumper to put Sacramento ahead by four, making Curry's buzzer-beating 3-pointer not enough to force overtime.

NOTES: Curry, who helped the U.S. to a gold medal in the FIBA world championships last summer, received his ring in a pre-game ceremony. ... Kings PG Evans hit the floor hard on a layup attempt in the second quarter. He was shaken up and limped off the floor after a minute, but he stayed in the game and showed no signs of being slowed. ... Warriors C Andris Biedrins missed his 12th straight game with a sprained left ankle and is not expected back for the final two games this season.