Peralta (8-11) allowed one run on five over 6 1/3 innings. Peralta struck out six before making way for a trio of relievers who close out the game. Jim Henderson picked up his 16th save in 1 1/3 innings of work.
Matt Cain (7-7) absorbed the loss after allowing two runs on four hits over seven innings. Cain also fanned six.
San Francisco was held scoreless until the seventh inning when pinch-hitter Joaquin Arias drove in Brandon Belt on a ground out to second base.
Millions of Getty images now available for free via embed tool
NBC reportedly holds celebs hostage to Jimmy Fallon's show