Confetti fell and Stephen Curry flexed. He danced and celebrated a January victory against the lowly Rockets as if it were a playoff game in May.

Oh how the Golden State Warriors needed this one. Curry needed this one.

His dependable, smooth shot abandoning him for much of the night again, Curry nailed a game-winning 20-foot jumper from the top of the key as the clock hit 0.0 and the buzzer blared, scoring 22 points and sending the Warriors past Houston 105-103 on Friday.

"It felt great," Curry said. "The way the whole last 48 hours have been with the way we played grinding out last night, going overtime, losing, the disappointment with that and then coming into this game, the back and forth, just grind-it-out mentality we had, the resilience we showed to give ourselves a chance the second half was impressive.

"It reminds you to keep the big-picture perspective on what we're trying to do."

Golden State Warriors guard Stephen Curry

Golden State Warriors guard Stephen Curry, left, chases the ball after fouling Houston Rockets guard Kevin Porter Jr. (3) during the first half of a game in San Francisco, Friday, Jan. 21, 2022.  (AP Photo/Jeff Chiu)

SUNS RALLY LATE TO BEAT MAVS, SWEEP 5-GAME ROAD TRIP

The sellout crowd went into a frenzy as Curry pumped his arms in triumph at midcourt, exhaling after he had missed two 3-pointers in the final 1:48. It was the first buzzer-beating winning shot of Curry's career. He had seven to win games in the final 5 seconds.

It had been since high school.

"It's just how the game kind of goes, I hit some shots .1, .4, 1 second, whatever it is, big shots," he said. "But it's a different feeling when it's a walk-off. It's good to know what that feels like finally."

Golden State Warriors guard Stephen Curry

Golden State Warriors guard Stephen Curry celebrates after the Warriors defeated the Houston Rockets in San Francisco Friday, Jan. 21, 2022.  (AP Photo/Jeff Chiu)

Curry overcame a slow start to lift the tired, mentally spent Warriors back up from an ugly loss to Indiana a night earlier. He also dished out 12 assists.

"I was shocked. I just talked to him. It was his first ever walk-off game-winner," coach Steve Kerr said. "Obviously he’s had plenty in the final seconds. I didn’t know that. A fitting end to a grind-out game that we really needed. I think in some ways we had forgotten how hard you have to play to win in this league.

"I think tonight our guys remembered that lesson."

BULLS' LONZO BALL TO HAVE KNEE SURGERY, SIDELINED 6-8 WEEKS

Houston had the ball with 11.5 seconds left and the game tied at 103, but Garrison Mathews missed a 3 and Otto Porter Jr. secured the rebound before a Warriors timeout.

Porter’s driving dunk with 3:38 to play got Golden State within 101-99.

Curry missed his initial eight shots — including an 0 for 5 in the first quarter when he had only a single free throw — and finally made his first field goal with a 3-pointer 48.8 seconds before halftime. Golden State trailed 54-43 at the break then went into the final quarter tied at 76.

The reigning scoring champion shot 6 for 21 with four 3's. Andrew Wiggins added 17 points for the Warriors following a 121-117 overtime loss to the undermanned Pacers on Thursday night.

Klay Thompson

Klay Thompson of the Golden State Warriors stands on the court prior to the start of a game against the New Orleans Pelicans at Smoothie King Center in New Orleans, La., Jan. 6, 2022. (Sean Gardner/Getty Images)

Klay Thompson sat out the second game of the back-to-back, and Jordan Poole scored 20 while returning to the starting lineup as rookie Jonathan Kuminga came off the bench.

Poole went down hard with 1:17 left in the third when Mathews clobbered him in the face, a play that was ruled a Flagrant 1 foul after review.

Christian Wood had 12 of his 19 points in the first quarter and grabbed 15 rebounds, and Kevin Porter Jr. scored 17 points for Houston, which wrapped up a five-game road trip. The Rockets came in having won three of four but dropped their fifth straight to the Warriors, including three in a row in the Bay Area.

CLICK HERE TO GET THE FOX NEWS APP

Golden State used a 33-point third quarter to get back in it a day after the Warriors shot a dismal 9 for 42 from 3-point range and coach Steve Kerr blamed himself for not having the team prepared to play a Pacers team missing three starters with injuries.

Golden State committed 21 turnovers against Indiana, another 19 on Friday and hasn't played the kind of smothering defense that defined the Warriors early on this season. And they are clearly missing injured Draymond Green's presence on both ends.

"Without Draymond, we lose a huge part of who we are identity wise, force wise, competitive wise," Kerr said.