AUBURN HILLS, Mich. — The Toronto Raptors spent 39 minutes trying to get their game into gear Friday night.

When they did, though, it went very well.

The Raptors trailed the Detroit Pistons 72-63 with 9:13 to play, but finished the game with a 24-3 run to post a comfortable 87-75 victory.

"The basketball gods are good to you when you play hard," Raptors coach Dwane Casey said. "We didn't shoot the lights out, but we played the game the right way on both ends, and when you do that, the shots will eventually fall."

Toronto wasn't spectacular offensively down the stretch, hitting seven of 14 shots, but it held the Pistons to one field goal in the final 9:31.

"All of that was defence," said Norman Powell, who played the entire fourth quarter, mostly guarding Kentavious Caldwell-Pope. "We know that defence will carry over into offence, and once we started getting stops, we were locked in. That makes it easy on the other end of the floor."

Serge Ibaka had 17 points and eight rebounds, while DeMar DeRozan added 14 points, eight rebounds and six assists for Toronto, which won for the second time in five games.

Reggie Jackson had 20 points for Detroit, which lost its third in a row and dropped to ninth in the Eastern Conference. Andre Drummond had 22 rebounds, but only had eight points before fouling out in the fourth quarter.

"I thought we played a strong defensive game until the last few minutes," Pistons coach Stan Van Gundy said. "Our offence was just nowhere to be found."

In Detroit's losing streak, they have shot 32 per cent outside the paint, including 30.4 per cent against Toronto. The Pistons hit three of 20 3-pointers against the Raptors, with Caldwell-Pope going 1 for 9.

"No one is trying to miss shots out there, but we can't hit a thing right now," Van Gundy said. "We're missing uncontested shots. You can't miss that many shots, turn the ball over 13 times and expect to win.

"I'm only surprised it was a close game for three quarters."

Both teams struggled offensively in the first half, posting matching 34.1 shooting percentages. Corey Joseph hit a pair of free throws with 1.1 seconds left in the half to give Toronto a 40-38 lead.

Jackson led the Pistons with 11 points, while Drummond had 15 rebounds. DeMarre Carroll had 10 points for the Raptors.

Toronto jumped out to a 53-46 lead early in the third, but the Pistons rallied to go ahead 59-58 on Caldwell-Pope's 3-pointer. Jon Leuer's tip in at the buzzer gave Detroit a 66-60 lead going into the fourth quarter.

The Pistons moved the lead to nine in the opening minutes of the fourth, but made one of their last 14 shots and missed the final 10.

"We just have to put in the work and shoot with confidence," Jackson said. "We are not panicking. Everyone has made a run, and with 13 games left, I know we are bound to make one before it is over."

TIP INS

Raptors: Came in with a 6-9 record in the second game of a back-to-back. They are 33-20 in all other games.

Pistons: Drummond scored his 5,000th career point on a lob from Ish Smith in the third quarter. It was also the 34th time he had 20 rebounds in a game, including seven this season.

STARTING AS YOU INTEND TO FINISH

The Pistons missed six of their first seven shots, falling behind 12-3, before going 1 for 14 in the final nine minutes.

MORRIS CONTINUES TO STRUGGLE

Marcus Morris went 1 of 13 from the floor after shooting 3 of 15 in Wednesday's loss to Utah. He is shooting 36.7 per cent from the floor in his last 13 games, even though that stretch included a career-best 37-point game against the Portland Trail Blazers.

OH, CANADIANS

As has become customary for Raptors games at the Palace, the crowd was cheering louder for Toronto than Detroit. Heavy snow in Auburn Hills kept fans of both teams at home, but Raptors jerseys dominated the small crowd.

UP NEXT

Raptors: Host the Indiana Pacers on Sunday.

Pistons: Host the Phoenix Suns on Sunday.