In a game that had 23 lead chances and was tied 11 times, neither team had much breathing room. Both converted big shots, but the Magic came up with the biggest down the stretch.
After the game was tied for the 11th time, Vucevic came up with a driving basket from the baseline in the waning seconds to give the Magic a 111-109 lead. Then, reserve Devyn Marble came up with a steal off Luol Deng' inbounds pass to Joe Johnson with 3.4 seconds remaining to all but seal it. Evan Fournier converted one of two free throws with 2.7 seconds left, and Miami's Dwyane Wade missed a halfcourt shot.
The loss snapped a two-game winning streak for the Heat (46-33) and made their fight to remain in the hunt for a top-four seed in the Eastern Conference playoffs that much tougher.
The Magic, who lost 14 of their previous 15 games to the Heat, improved to 34-45 and have won four of their last five games at the Amway Center.
The Magic shot 52 percent from the floor and 50 percent from 3-point range. But the real difference came at the free throw line where the Heat missed 10 free throws while the Magic converted 21 of 28.
The turning point in the game came when Vucevic accidentally hit Whiteside in the face while going for the ball. No foul was called, but Elfrid Payton scored on a continuation in transition. Whiteside came down the floor clearly upset and received a technical. Fournier converted the technical and Patyon made good on his three-point play by sinking his free throw to turn a three-point advantage into a 102-97 lead with 3:08 remaining.