CHICAGO (AP) Despite a large early deficit against a surging offense, Kyle Schwarber had little doubt the Chicago Cubs would rally.

''Crazier things have happened,'' he said. ''I just think it shows the character of our team. We're not gonna give up just because we're trading blows.''

Schwarber and Miguel Montero each hit a two-run homer, Albert Almora Jr. and Jon Jay added run-scoring hits in a four-run sixth inning and Chicago rallied from five down for a 9-7 win over the Milwaukee Brewers on Tuesday night.

Brewers slugger Eric Thames had two doubles and three hits but ended his franchise record-tying homer streak at five games.

Wade Davis got his third save and the bullpen retired 15 of its final 16 batters as the Cubs snapped a four-game skid. The bullpen had blown three straight save attempts in a weekend series against Pittsburgh.

''We're gonna be fine out there,'' Cubs manager Joe Maddon said. ''It's all about confidence. We just have to keep getting them out there. As they get more successful innings - which they shall - their confidence will come on because they're really good.''

The Brewers staked Jimmy Nelson to a 5-0 lead in the third, but the right-hander couldn't make it hold, allowing seven runs and nine hits in 5 1/3 innings. Reliever Jared Hughes (1-1) took the loss.

''Jimmy pitched much better than his line,'' Milwaukee manager Craig Counsell said. ''I thought he could have gotten a lot better fate.''

Brett Anderson pitched 3 2/3 innings and allowed six runs and eight hits. Justin Grimm (1-0) worked a scoreless sixth for the win.

Thames set a Brewers record by getting a hit in his 12th straight start to begin the season. The former Korean star has an extra-base hit in eight consecutive games.

Travis Shaw went 3 for 4 with a homer and three RBIs for Milwaukee.

''The middle of our lineup is carrying our offense,'' Counsell said. ''(Ryan) Braun and Thames are doing a heck of a job. Shaw a nice night.''

In the sixth, Montero singled with one out and Javier Baez followed with a double to put runners on second and third. Pinch hitter Almora drove in both with a single to left field to make it 7-6.

That chased Nelson, and then Jay greeted Hughes with a triple off the base of the wall in right-center to score Almora and tie it.

''It was just terrible execution on my behalf,'' Hughes said.

After Schwarber grounded out with the infield in, Jay scored the go-ahead run on a wild pitch by Hughes with Kris Bryant at the plate.

Bryant drove in an insurance run in the eighth.

TRAINER'S ROOM

Brewers: RHP Matt Garza (strained right groin) allowed five runs in 5 2/3 innings in a rehab start for Class A Wisconsin on Monday night. He threw 88 pitches (57 strikes) and appears ready to be activated from the 10-day DL. ''He's ready to go,'' Counsell said. ''We just have to figure out the best way to deploy it.''

Cubs: Anderson was hit in the lower left leg by a hard grounder in the first inning but stayed in the game.

GOLDEN MOMENT

Anthony Rizzo and Jason Heyward received their 2016 Gold Gloves before the game in an on-field ceremony.

MOVING FORWARD

Starling Marte, who was suspended 80 games on Tuesday for a banned substance, played a big role in the Pirates' sweep over the weekend. Maddon, though, refused to consider what might have been had his team not faced a player who tested positive for performance-enhancing drugs.

''I don't look in the rearview mirror,'' he said. ''I'm just glad that the drug policy, the drug enforcement, is working. That's all it means to me.''

UP NEXT

Brewers: LHP Tommy Milone (1-0, 7.36 ERA) makes his second start against Chicago this season in the series finale. He gave up four runs in four innings on April 8 and received a no-decision in an 11-6 loss.

Cubs: RHP Kyle Hendricks (1-1, 5.73 ERA) picked up the win against the Brewers on April 8.

Copyright 2017 by Associated Press. Any commercial use or distribution without the express written consent of Associated Press is strictly prohibited.