Melky Cabrera and Ryan Theriot each went 3-for-4 with two runs scored for the Giants, who have won eight of their last 10 games. Ryan Vogelsong (8-4) gave up just one run on four hits with three walks and six strikeouts over seven innings to get the win.
"He's been doing it all for us at the plate and behind the plate as always handles this staff great," Vogelsong said of Posey.
Yonder Alonso drove in the only run of the contest for the Padres, who came into the game having won five of six. Clayton Richard (7-11) was touched for seven runs on nine hits over just five innings to take the loss.
The Giants went on top in the first inning. With one out, Theriot doubled and Cabrera followed with an infield single. Posey then brought home one and Pablo Sandoval followed with a walk to load the bases. Angel Pagan then drew a walk to force in one and Joaquin Arias grounded into a fielder's choice that plated another.
Brandon Crawford then hit a fly ball to left that was initially ruled an out as it appeared that Mark Kotsay caught the ball. Crawford was ruled out and both teams went to their dugouts, but the umpires then huddled and determined that Kotsay trapped the ball. Crawford was awarded a single and Sandoval came home for a 4-0 lead.
In the fourth, the Padres got a run when Alonso's sacrifice fly scored Kotsay, who had singled and moved to third on a Yasmani Grandal double.
Posey, though, put the game away in the fifth when he blasted a shot over the wall in right with Theriot and Cabrera on base.
"Backbreaker was Posey's homer," San Diego manager Bud Black said.
San Diego didn't have a man advance past second base after the fourth inning.
San Diego center fielder Alexi Amarista left the game in the seventh with a jammed left thumb...San Francisco has won five of the seven games against San Diego this season...San Francisco batted 5-for-7 with runners in scoring position, while San Diego went 0-for-7 and left seven on base.
For more on the Giants, make sure that you check out McCovey Chronicles.