With the score tied 2-2 in the fifth, Marco Scutaro led off with a single against Rockies starter Jon Garland and one out later Hunter Pence reached when second baseman DJ LeMahieu couldn't handle his pop fly.
That brought up Belt, who sent a 3-2 pitch over the head of center fielder Dexter Fowler for a two-run double.
Belt then scored when Andres Torres followed with another two-bagger, and the Giants went on to claim the rubber match of a three-game set.
Cain (4-2) got the victory despite allowing five walks in five innings. The Giants ace yielded two runs on two hits while striking out six.
Garland (3-6) surrendered five runs (three unearned) on seven hits in a five-inning performance.
Michael Cuddyer drove in two runs for the Rockies.
Notable deaths of 2014 [PHOTOS]