Paul Goldschmidt added an RBI single for the Cardinals.
St. Louis starter Zack Thompson (3-5) gave up two runs and six hits in five innings, with five strikeouts and one walk.
JoJo Romero got a two-inning save, his third.
Ke'Bryan Hayes homered and Connor Joe hit an RBI double for the Pirates.
Pittsburgh starter Luis Oritz (2-4) allowed five runs and seven hits in 3 1/3 innings, with five walks and five strikeouts.
With one out in the first, the Cardinals' Alec Burleson reached on a bunt single and went to second on catcher Jason Delay's throwing error. Goldschmidt drove in Burleson with a single to center for a 1-0 Cardinals lead. Arenado and Willson Contreras walked to load the bases. After Andrew Knizner struck out, Palacios doubled to right, with Goldschmidt and Arenado scoring to push it to 3-0.
With one out in the second, Burleson and Goldschmidt walked. Arenado brought both home with a double to left to increase the lead to 5-0.
The Pirates got on the board in the third. With one out, Delay flared a single to center. He went to third on Hayes' double. After Bryan Reynolds popped out, Andrew McCutchen walked to load the bases. Thompson hit Joe with a pitch to force in a run and cut it to 5-1.
With one out in the fifth, Hayes hit his ninth homer to slice it further to 5-2.
With two outs in the top of the sixth, the game went into a 92-minute rain delay.
In the bottom of the sixth against Andre Pallante, Liover Peguero singled to right with one out and stole second. Ji Hwan Bae and Alika Williams walked to load the bases. Peguero scored on Delay's groundout to make it 5-3.
The Cardinals added a run in the ninth on Masyn Winn's forceout RBI, and Pittsburgh added one in the bottom of the ninth on Joe's RBI double.
—Field Level Media