MILWAUKEE -- Matt Clark's first home run of his career is something he'll likely never forget. Or maybe he already did.
"I don't really remember much of it," Clark said. "I think they gave me a concussion when I walked through the dugout. It was definitely an awesome feeling."
Peralta (16-10) gave up one earned run and five hits in 6 2/3 innings to help Milwaukee snap a four-game losing streak and win for just the second time in its last 15 games. The right-hander also had an RBI for the Brewers, who remained 1 1/2 games behind Pittsburgh for the second wild-card spot.
"I really liked the way Wily came out and threw the ball," Milwaukee manager Ron Roenicke said. "He set the tone. His fastballs were outstanding. He threw more change-ups today. That's the best change-up I've seen him have."
Francisco Rodriguez got the last three outs to reach 40 saves for the fifth time in his career.
Miami's Jarred Cosart (4-2) allowed an earned run and four hits in six innings, striking out seven. He had won his last four decisions.
Marcell Ozuna hit his 22nd home run of the season to lead off the seventh for Miami.
Rodriguez, who gave up three runs in the ninth in a 6-3 loss Tuesday, last topped the 40-save mark in 2008 when he set a major league record with 62 while with the Los Angeles Angels.
The Brewers took a 1-0 lead in the third when Jean Segura reached second base when shortstop Adeiny Hechavarria fielded his ground ball and threw it over the head of first baseman Garrett Jones. As Segura went to second, Miami thought he failed to touch first. But when Cosart threw the ball to first to appeal the play, Segura took third and scored on the next pitch on Peralta's sacrifice fly.
Official scorer Tim O'Driscoll initially ruled Segura's advancement to third as a fielder's choice. After discussing the play with the Elias Sports Bureau, however, he changed it to a stolen base.
"That was on my shoulders for kind of lobbing the ball over there and giving Segura a chance to get to third," Cosart said.
Added Miami manager Mike Redmond: "That was a crazy play, no doubt."
Clark, a September call-up making his second start, got his first career RBI on a sacrifice fly in the fourth. He then led off the bottom of the seventh with his homer to right for a 3-1 lead.
Shortly after Jonathan Lucroy became the third Brewers player all-time to hit 50 doubles in a season, he was thrown out at the plate by left fielder Christian Yelich on a single by Aramis Ramirez in the first inning. Not only did the fans loudly cheer when the replay was shown, nearly every Miami player returned to the infield. Home plate umpire Dan Bellino, while the play was still under review, even tossed the ball back to Cosart as he walked to the mound. But shortly after, Lucroy was still ruled out.
Milwaukee recalled relief pitcher Rob Wooten from Triple-A Nashville prior to the game. He was 1-4 with a 4.59 ERA with the Brewers this season. ... The Brewers sent minor-league right-handed pitchers Kevin Shackelford and Barrett Astin to Cincinnati to complete the Aug. 31 trade for pitcher Jonathan Broxton from the Reds.
Brewers: Ryan Braun did not start for the second game in a row. The right fielder has been dealing with an injury to his right thumb that spread to his hand.
Marlins: Nathan Eovaldi (6-10) is 0-4 with a 4.91 ERA in his career against Milwaukee.
Brewers: Mike Fiers (5-2) is 0-2 in his career against the Marlins.