Madison Bumgarner headed up the dugout steps for the ninth inning when manager Bruce Bochy asked how he was feeling.

''Why are you asking?'' San Francisco's ace cracked.

Minutes later, he completed a five-hitter with 12 strikeouts, backed by Brandon Belt's two solo home runs that broke up a pitcher's duel as the San Francisco Giants beat the Houston Astros 3-1 on Tuesday night.

More from FoxSports

''We've seen now he definitely can sense a big moment and seems to pitch his best in big games,'' catcher Buster Posey said.

Belt's homers, in the fourth and sixth innings, gave him 17 this season to match his career high, also done in 2013. It was his third career multihomer game and second this year for the defending champion Giants, who bounced back at home after being swept by the Cubs in four games over the weekend at Wrigley Field.

''Huge lift,'' Bochy said. ''You get in a tough deal like we get in losing four straight there and it's usually a well-pitched game that gets you out of it. He threw a beautiful game.''

Bumgarner (13-6) outpitched fellow southpaw Scott Kazmir (6-7) in an anticipated interleague matchup of top lefties for the World Series MVP's eighth career complete game and second this season. He didn't walk a batter in the 105-pitch gem and at one point struck out seven consecutive hitters.

Kazmir, who had allowed only one earned run for a 0.44 ERA in three starts since joining his hometown Astros in a July 23 trade from Oakland, committed two throwing errors while losing his second straight start.

Bumgarner posted his 23rd career double-digit strikeout game and fourth this season. He surrendered a triple to Evan Gattis in the seventh on a ball center fielder Gregor Blanco had in his glove but dropped after crashing into the wall. Chris Carter drove home Gattis with a single two batters later to put the Astros on the board.

''We ran into one of the better pitchers in the bigs. He really had good stuff and we couldn't really rally against him,'' Astros manager A.J. Hinch said. ''He's one of the best and you try to scratch and claw a little bit. We had a chance to score early but when he needed, he pitched tough.''

Bumgarner won for the fifth time in six starts. The seven consecutive strikeouts matched the San Francisco-era record also done by Jonathan Sanchez on Aug. 3, 2010, at Colorado, and Hall of Famer Juan Marichal on Sept. 6, 1964, at Philadelphia.

''That's quite a feat,'' Bochy said. ''The last one to do it was Sanchez, Johnny at Colorado. That shocked me.''

Kazmir again lasted 5 2/3 innings, giving up two earned runs and seven hits, struck out three and walked two.

Giants left fielder Nori Aoki, who left Sunday's game in Chicago after he was hit in the head by a pitch in the third inning, was given one more day off as a precaution. He is set to start Wednesday.

''Good for tomorrow,'' he said.

SPECIAL VISIT

Hinch had the rare day off Monday in his adopted hometown of Stanford after playing in Oakland. He visited his alma mater and watched the Cardinal's opening football practice on campus.

''I love the Bay Area,'' he said. ''I consider this place like a second home.''

TRAINER'S ROOM

Astros: RF George Springer will have his fractured right wrist re-evaluated by a doctor once the team returns home to determine when he can begin strengthening and other rehab work. He was hit with a fastball by Edinson Volquez on July 1 at Minute Maid Park. ''We're all anxiously waiting,'' Hinch said. ''I'm hopeful the next appointment will tell us we can progress in baseball activities.''

Giants: CF Angel Pagan went on the 15-day DL with patella tendinitis in his right knee. ... RHP Tim Lincecum (bruised right forearm) threw a 40-pitch bullpen session he considered on par with a regular ''in-between-start bullpen.'' He remains optimistic he will pitch again this year. ... RHP Tim Hudson threw a bullpen to test his strained throwing shoulder, and the Giants will discuss their next move with him as he was eligible to be activated Tuesday. ... Backup C Andrew Susac was relegated to a DH role in his rehab assignment for Class-A San Jose following a root canal Monday.

UP NEXT

Astros: RHP Scott Feldman tries again for his first career victory vs. the Giants after starting 0-4 in five appearances and three starts, including 0-3 at AT&T Park.

Giants: Rookie RHP Chris Heston, knocked out of his last two starts without reaching five innings, looks for another fine start against the Astros after he tossed his first career complete game at Houston on May 12.