The Galaxy (5-9-7) grabbed the lead in the 15th minute when Boyd took passes from Puig and Mark Delgado and scored for a fourth time this season.
Mikael Uhre scored unassisted in the 35th minute to pull the Union (10-7-4) even. It was his seventh goal of the campaign.
The Galaxy took a 2-1 lead into halftime on Mbaizo’s own-goal in the first minute of stoppage time.
Puig added an insurance goal — his third score of the season — in the 76th minute with assists from Dejan Joveljic and Douglas Costa.
Jonathan Klinsmann turned away one shot for the Galaxy. Joe Bendik had five saves for Philadelphia.
The Galaxy improve to 9-1-3 all-time against the Union. They are 6-0-2 in the last eight match-ups.
The Galaxy beat defending champion LAFC 2-1 their last time out and is 3-0-4 in its last seven contests after a rough start.
Philadelphia has allowed multiple goals in four of its last five matches after doing so just twice in its previous 11.
The Galaxy are 4-0-2 this season when Puig contributes to a goal and 1-8-5 when he does not.
The Galaxy travel to play the Vancouver Whitecaps on Saturday.