Milwaukee starter Marco Estrada hit a two-run double in a six-run first inning but injured his leg rounding first base and came out of the game.
"When I saw the third baseman miss the ball I tried to push off and that's when I felt it pop," Estrada said of his hit to left field and the resulting injury.
Aramis Ramirez had a three-run double in the first and Jonathan Lucroy belted a two-run homer in the second for the Brewers, who bounced back from losses in the first two games of the series to avoid a sweep.
Zito (3-2) gave up five hits and four walks but only four of the eight runs charged to him in three innings were earned. He struck out three and had a two-start winning streak snapped.
Zito threw 44 pitches in the first inning against 10 Milwaukee batters and had a throwing error on a bunt. Ramirez knocked in the first three runs with no outs on a double to left-center field.
The other big knock was Estrada's double on a line drive past Joaquin Arias, who seemed to lose the ball at third as it came out of the shadows and into the sunlight.
Estrada clutched his upper right thigh as he rounded first base. He made it to second easily, but came out of the game after being looked at. Zack Greinke entered as a pinch runner and Manny Parra took the mound in the second for Estrada, who had struck out two in a perfect first.
The Brewers said Estrada had a strained right hip flexor and was set to have an MRI.
Parra, Kameron Loe, Jose Veras (3-1), Francisco Rodriguez and John Axford all worked out of the bullpen to finish the game. Veras earned with win with three strikeouts in two perfect innings and Axford struck out two in a 1-2-3 ninth for his seventh save.
"With the injuries that we've had that bullpen has thrown a lot," said Brewers manager Ron Roenicke. "With a couple of clean plays, Manny (Parra) also would have had a clean inning. The bullpen was really good. The day off tomorrow is big for all of us."
Norichika Aoki reached on a close play at first base leading off the second inning -- Zito covered for Brandon Belt on the grounder to first -- and Lucroy knocked a two-out pitch over the wall in left-center to make it 8-0.
Hector Sanchez hit a three-run double off the left field wall in the third inning to get the Giants on the board, and they scored two more after Loe came in for Parra to start the fourth.
Brandon Crawford knocked in a run with a single to center and Melky Cabrera added an RBI double to make it 8-5.
"It was a great comeback but we were just too far behind," said Giants manager Bruce Bochy. "What a job the [bullpen] did. We have to pick it up defensively. It's what killed us in the first inning."
The Brewers snapped a four-game losing streak to the Giants. They won for only the second time in their last eight games overall and improved to 2-4 on a six-game homestand. They will start a seven-game road trip on Friday with the opener of a weekend series against Arizona...The Giants will wrap up a seven- game road trip with four against the Marlins in Miami starting Thursday.
For more on the Giants, head over to McCovey Chronicles.