James' driving layup with 1:07 remaining in the extra frame gave him 36 points for the game and handed the Heat a 110-108 lead.
Wade (21 points) then secured the victory when he picked off an inbounds pass from the Magic's J.J. Redick with 9 seconds left and slammed it home.
Chris Bosh contributed 22 points on 10-of-15 shooting as Miami erased an 11-point, third-quarter deficit and snapped a two-game skid.
Orlando, meanwhile, fell to a sixth consecutive defeat despite 20 points and a franchise-record 29 rebounds from Nikola Vucevic.
Arron Afflalo led the Magic's scorers with 28 points and Redick canned five 3-pointers en route to 23 for Orlando.
|Additional Sports News Stories|
CANNES, France, May 25 (UPI) --A Russian man paid $1.5 million to sit next to Leonardo DiCaprio on the maiden voyage of the Virgin Galactic trip into space.
WASHINGTON, May 24 (UPI) --The U.S. Food and Drug Administration says it's taken a close look at a mobile app that analyzes photos of urine samples and has been in contact with its maker.