Cole Anthony scored a career-high 26 points but none was bigger than the final three.
Anthony drained a 3-pointer with 0.1 seconds left as the Orlando Magic rallied from 20 points down to beat the Memphis Grizzlies 112-111 on Saturday night at Amway Center.
It was the second game-winning shot for Anthony, who beat the Timberwolves earlier this season on a buzzer-beating 3.
Moritz Wagner scored a season-high 24 points, Dwayne Bacon had 23 and R.J. Hampton finished with a career-high 18 points for the Magic (20-44), who split their two games with the Grizzlies after losing Friday in Memphis.
Dillon Brooks scored 23 points, Ja Morant had 22 and Kyle Anderson had 21 for the Grizzlies (32-31).
Orlando enjoyed a 25-13 scoring edge from the free-throw line, in part because Memphis went 13-for-21.
The Magic played without starting forwards Chuma Okeke and James Ennis, shooting guard Terrence Ross (back spasms), point guard Michael Carter-Williams (ankle sprain) and forward Otto Porter Jr. (foot pain). Their absences left Orlando with just nine available players.
The short-handed Magic trailed 60-48 at halftime and appeared headed for another double-digit loss after the Grizzlies went up 77-57 on a putback by Jonas Valanciunas.
But Hampton scored six points to help spark the Magic, who made up 12 points with a 19-7 run over a 5:06 stretch of the third quarter.
The Magic kept surging as Anthony scored six points in a key stretch and his 3 cut the Memphis lead to 95-91 with 6:58 left.
Two free throws by Anthony later pulled the Magic within 98-95, the closest they had been since trailing 29-27 late in the first quarter.
It was a seven-point deficit when Bacon sank a 15-footer and Anthony made two free throws to make it 106-102.
After Morant hit a 3, Hampton responded with a 3 in transition after a steal by Bacon to pull Orlando within 109-106.
Wagner then drained a 3 to tie it at 109-109 with 1:16 left.
Brooks drained an 18-footer over Bacon to beat the shot clock, giving Memphis a 111-109 lead with 7.0 seconds left.
That set up the final sequence. Anthony inbounded, then got the ball back from Bacon. He dribbled to his right, then came back left and pulled up to shoot over the 6-foot-9 Anderson. The shot went through with 0.1 seconds left.
The Magic will be in Detroit to face the Pistons on Monday. The contest tips off at 7 p.m. and will be broadcast on Bally Sports Florida.