The Giants grabbed control in the fourth with a four-run uprising.
They forged a 2-0 lead on a Pablo Sandoval single and a run-scoring balk by pitcher Henderson Alvarez before Blanco lined a pitch that got past diving center fielder Jake Marisnick and rolled to the wall for a two-run triple.
Sandoval finished with two RBI and Andres Torres also drove in a run for San Francisco, which clinched its three-game series.
Cain (8-8) allowed two runs on four hits over seven solid innings, walking two and striking out five.
Alvarez (2-2) ended up yielding four runs on four hits over seven innings.
Giancarlo Stanton clouted a mammoth two-run homer and Logan Morrison also drove in two runs for the Marlins.
Notable deaths of 2014 [PHOTOS]