Updated

Hunter Pence hit a three-run homer in the first inning and the San Francisco Giants went on to beat the Houston Astros 6-4 on Wednesday night.

Joaquin Arias added a two-run triple for the Giants, who have won the first two games of the three-game series and nine of their last 12.

Barry Zito lasted just 2 1/3 innings, giving up three runs on seven hits, and George Kontos (1-0) earned his first win in 39 major league appearances with 2 2/3 perfect innings, striking out four.

Astros starter Dallas Keuchel (1-7) retired 14 batters in a row after Pence's homer in the first inning but took the loss. Four of the five runs he gave up in five innings came in the first.

The Astros have lost four in a row and are 1-11 in their last 12 games.

There was a record-low attendance for the second day in a row at Minute Maid Park. The 13,207 fans Wednesday night came after the teams drew 13,516 on Tuesday.

"The vibe in the clubhouse and in the dugout has been positive," Astros first baseman Brett Wallace said despite the struggles. "I feel like the energy level has been high. We've been in a lot of games we've played."

The Giants jumped on Keuchel in the first. After Angel Pagan hit a leadoff double and scored on Pablo Sandoval's single, Buster Posey walked and Pence cleared the bases with his 19th homer of the season.

Chris Snyder hit a one-out double in the second inning and scored Houston's first run on Brandon Barnes' single. The Astros pulled within 4-3 in the third on Wallace's RBI single and Jimmy Paredes' sacrifice fly.

Zito came out after giving up a single to Fernando Martinez. He and Kontos were just two of seven pitchers used by the Giants and manager Bruce Bochy credited one of them in particular for coming up big.

"First guy in saves you and that's what Kontos did. Gave us two good innings," said Bochy.

San Francisco pushed its lead to 6-3 in the sixth, sparked by a leadoff double from Marco Scutaro. After Keuchel walked Sandoval he was replaced by Mickey Storey, who got Posey on a double play.

But Pence reached on Scott Moore's throwing error from third and Arias drove a ball to left that Martinez dove for and missed, ending in a two-run triple.

Moore hit an RBI single in the sixth but the Astros had just two more runners the rest of the game. Javier Lopez came in for Santiago Casilla in the ninth and got a double play to end the game and earn his fifth save of the season.

Game Notes

The Giants have won a season-high five in a row on the road ... Bochy evened his career record at 1,433-1,433 ... Keuchel is winless (0-7) in his last 10 starts.