Kyle Lowry poured in 36 points to lift Toronto to a nailbiting 115-113 victory over the Brooklyn Nets on Wednesday, giving the Raptors a 3-2 lead in their best-of-seven playoff series.

DeMar DeRozan added 23 points, while Jonas Valanciunas finished with 16, and Greivis Vasquez added 15.

Amir Johnson chipped in with 11 points for the Raptors who gave up a 26-point lead in the fourth quarter, making for some tense moments at the Air Canada Centre, but held on for the victory.

Joe Johnson led the Nets with 30 points, while Mirza Teletovic added 17, and Deron Williams and Alan Anderson finished with 13 apiece.

The series heads back to Brooklyn’s Barclays Center for Game 6 on Friday.

The Raptors controlled the game through second and third quarters where it seemed they could do no wrong, and led by 26 points twice late in the third.

They headed into the fourth up 91-69 advantage and appeared poised to cruise to an easy victory, but the Nets had plenty of fight left in them, tying the game at 101-101 on a three-pointer by Johnson with 3:16 to go and stunning the crowd.

Vasquez and Teletovic traded threes and it was tied with 1:23 to go before Lowry drained a three and then scored on a driving hook shot to put Toronto up by three with 27 seconds left.

Two DeRozan free throws put Toronto up by five, but Alan Anderson was fouled on a three to pull the Nets to within a point with 10 seconds to play. DeRozan and Blatche traded free throws then Blatche chucked a wayward ball meant for Williams that was ruled a backcourt violation, sealing the victory.

The rock-solid Lowry, playing with his right knee in a protective brace after injuring it in Game 3 in Brooklyn, had his best game of the series, providing all kinds of highlight-reel plays.

There was the diving 31-footer he drained at the buzzer to cap the first half that left him sprawled laughing on the floor. There was the 85-foot outlet pass that found an unmarked Terrence Ross under the basket.

But the point guard was particularly big down the stretch, taking charges and slicing through the Nets’ defence for buckets.

The teams split the first two games in Toronto, and did the same in Games 3 and 4 in Brooklyn. A Game 7, if necessary, would be Sunday in Toronto.

The capacity ACC crowd of 19,800 that included Drake and rapper 50 Cent — who dipped his head when the camera was on him to show fans his “Northern Uprising” hat — was loud all game long, from the moment the fans sang along to O Canada to the final buzzer.

The arena was a sea of white, as fans wore their white “We The North” T-shirts. They mocked the Nets by chanting “Broo-klyn!” the traditional chant at the Barclays Center.

The Nets even took note, posting on the team’s official Twitter account: “#Nets fans take note- this is what a playoff crowd sounds like..set your DVD and take notes #RAPTORSvNETS.”

Despite the rain and chilly temperatures, some 4,500 fans jammed into Maple Leaf Square outside the ACC to watch the game on the big screen. They were given rain ponchos. Some 1,200 fans were also given black and gold OVO/Raptors lint-rollers, a nod to Drake using a lint-roller while sitting courtside during Game 2.

An array of Toronto sports celebrities took the stage, including Toronto FC’s Jermain Defoe, Michael Bradley and Julio Cesar, and former Raptors Morris Peterson and Jerome Williams.

“I’ve never seen support like this. This is special,” Defoe said in an on-stage interview. Cesar, wearing a No. 7 Raptors jersey, yelled “Let’s go Raptors!”

This series has been spirited from Day 1 when Raptors GM Masai Ujiri took the stage and dropped his famous F-bomb about Brooklyn.

An enterprising man outside the ACC on Wednesday was selling F— Brooklyn buttons, three for $5. Fans were wearing the same on T-shirts at the game.

Johnson led the way with nine points for Toronto in a first quarter that saw neither team lead by more than six. The Raptors ended the quarter with a 10-2 run capped by a Lowry three-pointer that put Toronto up 28-25 going into the second.

The Raptors trailed by four points with just over five minutes to go in the second, but finished the quarter on a 26-4 run capped by Lowry’s three, part of a 13-point performance in the quarter for the point guard. The Raptors went into the locker-room at halftime buoyed by a 62-44 lead.

The third quarter has been the Raptors’ nemesis in this series, but not so on Wednesday. They didn’t take their foot off the pedal, shooting 58 per cent to twice go ahead by 26 points. Toronto went into the fourth with a 91-69 lead.