Memphis, which has alternated wins and losses during its last six contests, got 15 points each from Mike Conley and Juan Carlos Navarro. The Grizzlies won on the road for only the eighth time this season.
Earl Barron scored a career-best 22 points for Miami.
Miami has lost eight of nine and, with a 14-65 record, clinched a last-place finish in the NBA.
The Heat trailed by just five going into the fourth quarter, but Memphis began the period on a 9-0 run.
Miami established a franchise record for three-point field goals in a season with 596.