Matt Holliday homered for the Cardinals, who took control with a four-run second inning highlighted by Wainwright's fifth extra-base hit of the season.
With two on, two outs and a run in, Wainwright lined the first pitch from Gio Gonzalez (3-3) into the left-center gap. Matt Carpenter, activated from the paternity list before the game, followed with an RBI double for a 4-0 lead. That started Wainwright (5-3) on a path to his fifth straight win. The right-hander allowed four runs and six hits — including a career-record tying three home runs. He struck out five and walked none.
Ryan Zimmerman went 4 for 4 with two homers, and Bryce Harper hit a solo shot for the Nationals.