Try 3 months for $3

MILWAUKEE — It was a grand evening for the Milwaukee Brewers — until the final nail-biting ninth inning.

Travis Shaw hit a grand slam during Milwaukee’s six-run first inning, and the Brewers beat the Colorado Rockies 8-4 on Saturday night at Miller Park, holding on when Josh Hader retired Charlie Blackmon on a pop fly to Jonathan Schoop in short right field with the bases loaded.

Rookie Freddy Peralta pitched six effective innings in his second win over Colorado this season.

Milwaukee (65-49) won for the fourth time in six games stayed one back of the National League Central-leading Chicago Cubs (64-46), who held on for a 5-4 win over San Diego. Peralta (5-2) said seeing his teammates give him a 6-0 lead was a real boost.

“That was awesome. Makes you feel like you have more confidence,” Peralta said.

Trevor Story hit two two-run homers for the Rockies, who have dropped five of six. Tyler Anderson (6-4) was tagged for seven runs and seven hits in four innings.

Story’s 23rd homer off Matt Albers caromed off the yellow padding on top of the wall in the ninth. A 50-second replay review confirmed the call.

The Rockies then loaded the bases with one out, but Joakim Soria struck out pinch hitter Tom Murphy swinging and Hader got Blackmon to pop out for his eighth save.

Anderson (6-4) held the opposition to a .144 average in his previous six starts, but Milwaukee jumped all over him right from the start.

Ryan Braun hit an RBI single before the lefty-batting Shaw drove a 1-0 pitch from Anderson over the wall in right for his first homer off a lefty this season. It was his second career grand slam.

“It felt good. I was just trying to get the ball in the air and get the guy in from third,” Shaw said.

Hernan Perez followed with his ninth homer of the season. It was the sixth time this year that Milwaukee hit consecutive home runs.

“It was huge,” manager Craig Counsell said of the big first inning. “A bunch of good at-bats in the first inning.”

Braun led off the third with a drive that bounced on the top of the padded wall in left for his 12th homer. Manny Pina made it 8-2 with a sacrifice fly in the sixth.

Peralta struck out eight while throwing a career-high 107 pitches. He allowed two hits and walked two.

Christian Yelich went 3-for-4 and leads the NL in batting average at .326.

“He’s unbelievable. What he’s done the past three weeks is unbelievable,” Shaw said of Yelich. “If he doesn’t get a hit, everyone’s shocked.”

Williams to DL

Brewers reliever Taylor Williams was placed on the 10-day disabled list with right elbow soreness. He was replaced on the roster by right-hander Jacob Barnes, who is back for his third stint with the Brewers after being recalled from Class AAA Colorado Springs. He pitched the eighth and gave up a hit.