TORONTO — Stephen Curry and Klay Thompson combined for three 3-pointers in the final three minutes, and the Golden State Warriors held on to defeat the Toronto Raptors 106-105 Monday night in Game 5 to stay alive in the NBA Finals.

The Raptors attempted a title-winning shot, but Kyle Lowry’s 3-point try from the corner hit the side of the backboard at the buzzer.

The best-of-seven series resumes (Friday) in Oakland, California, with Toronto leading 3-2.

Curry finished with 31 points, eight rebounds and seven assists, though he hit just 10 of 23 shots from the floor and 5 of 14 from 3-point range.

“Missed shots can’t kill your confidence. I’m going to get my legs ready for Game 6 and take those same shots,” Curry said. “I have whole lot (to give). We know how hard it is. We gave ourselves a chance. It’s doing to be a dogfight for 48 minutes. We’ll be ready.”

Thompson scored 26 points, and DeMarcus Cousins added 14 points for Golden State. Draymond Green had 10 points, 10 rebounds and eight assists.

Kevin Durant had 11 points and two rebounds for the Warriors before being helped from the court with 9:46 remaining in the first half with a lower right leg injury. He did not return. Durant had missed the previous nine games due to a calf strain.

Curry said on the ABC broadcast regarding what Durant’s effort meant, “He sacrificed his body for us. I’ve got a lot of emotions right now.”

Kawhi Leonard had 26 points — 12 in the fourth quarter — and 12 rebounds for the Raptors. Lowry added 18 points, Marc Gasol had 17, Serge Ibaka 15, Pascal Siakam 12 and Fred VanVleet 11.

The Warriors trailed by six with 2:30 to go before going on a 9-0 run that consisted of a pair of Thompson 3-pointers and another from Curry.

Golden State overcame two goaltending calls on Cousins in the final 1:59, plus an over-and-back violation on Draymond Green and an offensive foul for a moving screen on Cousins with 14.9 seconds left, setting up the final possession.

The Warriors took a six-point lead into the fourth quarter after leading by as many as 14 in the third.

The Raptors cut the deficit to three points on Ibaka’s dunk with eight minutes to play, and Leonard’s put-back trimmed the margin to one.

Draymond Green’s 3-pointer had Golden State ahead by four, but Norman Powell’s running dunk cut the deficit to two with 5:36 to go.

Toronto took a three-point lead on Leonard’s 3-pointer and followed by a jump shot with 4:46 to play. Leonard hit another 3-pointer and added a pullup jumper to give Toronto a six-point lead with 3:28 to play.

Thompson’s 3-pointer trimmed the gap to three with 2:32 left.

Toronto was called for a shot-clock violation, and Curry tied the game at 103 with a 3-pointer. After Leonard’s miss, Thompson came back with a 3-pointer with 57.6 seconds remaining, and the Warriors led by three.

Lowry’s layup cut the lead to one point with 29.9 seconds to play.

Cousins was called for an offensive foul with 15.7 seconds to play, giving Toronto a chance, but Lowry missed his shot as time expired. — Reuters