Leonard banked home the tiebreaking basket with 4.2 seconds remaining and the Raptors edged the Brooklyn Nets 127-125 on Monday night.
"I asked if he called 'bank,'" Toronto coach Nick Nurse said. "He said he called 'game.'"
Gasol scored 16 points, 11 in the fourth quarter, in his home debut after being acquired from Memphis last Thursday.
"I definitely got more comfortable," Gasol said of his big quarter.
D'Angelo Russell scored 28 points and had a career-high 14 assists for Brooklyn. Joe Harris scored 24 points and made a career-best seven 3-pointers, but the Nets lost for the fifth time in six games.
The Nets gave the ball to Russell on their final possession, but his long shot bounced off the rim and into Kyle Lowry's hands.
Lowry and Patrick McCaw each scored 13 for the Raptors, who have won 14 of 15 against Brooklyn.
Allen Crabbe made six 3-pointers and scored 22 points, while Jarret Allen scored 15 for the Nets.
Toronto led 120-114 on a 3 by Lowry at 2:45 of the fourth but Crabbe replied with back-to-back 3-pointers to tie it at 120 at 1:34.
Russell hit a tiebreaking 3 with 50 seconds to go, but Danny Green answered with a 3 for the Raptors.
With the teams tied at 92 to begin the fourth, Gasol scored 11 of Toronto's first 13 points in the final quarter.
"It was a heck of a stretch for him," Nurse said. "Really fun, really impressive."
Nets coach Kenny Atkinson had praise for Gasol, too.
"I thought he commanded in the post," Atkinson said. "I could really see him anchoring that second unit and making them very dangerous."
Gasol received a standing ovation when he replaced Ibaka at 3:03 of the first.
"It gives you the butterflies in your stomach," Gasol said of the rousing welcome. "It made you feel like a rookie again. It's a great feeling to have."
Harris made five of six from 3-point range in the first quarter and Brooklyn led 29-21 after one. The five 3-pointers are the most Harris has made in a single quarter, and matched his season high for an entire game.
The Nets led 60-56 at halftime.
Nets: Brooklyn shot 20 for 41 from 3-point range, matching their season high for made 3-pointers. ... F DeMarre Carroll (left knee) was not available. Atkinson said Carroll should return Wednesday at Cleveland.
Raptors: Toronto has won five straight. ... This was the first of six consecutive home games for the Raptors, who don't play on the road against until March 3 at Detroit. ... Musician Sting attended the game.
CHANGING OF THE GUARDS
Raptors guard Fred VanVleet was not available. Before the game, the Raptors said VanVleet will miss at least three weeks because of a ligament injury in his left thumb. VanVleet was hurt in the second quarter of Saturday's win at New York.
Toronto acquired some insurance at the point guard position Monday when they agreed to sign veteran Jeremy Lin, who is being waived by the Atlanta Hawks. Lin will sign with Toronto later this week, said Jim Tanner, one of his agents.
NOT CLICKING YET
In his second game since missing 42 with a right foot injury, Caris LeVert shot 3 for 11 and scored six points.
"Is he clicking on all cylinders? No, but I don't care, quite honestly," Atkinson said.
Nets: Visit Cleveland on Wednesday night.
Raptors: Host Washington on Wednesday night.
More AP NBA: https://apnews.com/NBA and https://twitter.com/AP-Sports