Howard, who starred for the Magic for eight years, was lustily jeered by the Orlando crowd throughout the contest in his first game facing his former team.
The Magic sent the notoriously poor foul shooter to the free-throw line time and again, but he responded by going 23-of-30 after missing seven of his first nine attempts.
His 39 foul shots tied his own NBA record, first set last year against Golden State.
Howard's point total was a season-high and he also hauled down 16 rebounds for the Lakers, who reeled off a fourth straight win and ninth in 11 contests.
Jamer Nelson netted 21 points and had seven assists for the Magic, who fell to 10-25 at home.
Tobias Harris added 17 points with 15 rebounds and Arron Afflalo also scored 17 for Orlando.