Bumgarner (8-4) allowed two runs on Nolan Arenado's 23rd homer in the first and five hits in 7 2/3 innings. He also belted a solo shot in the seventh and recorded his 1,000th career strikeout.
Arenado extended his hitting streak to 15 games and set a franchise record for consecutive games (12) with at least one hit and one run scored.
Posey's 26 RBIs in June are second only to Arenado's 33. Posey's two-run single in the third put the Giants ahead to stay.
Colorado right-hander Kyle Kendrick (3-10) was charged with five runs and eight hits in 5 2/3 innings.
Duffy tripled in the first, doubled in the third and hit a home run in the sixth. He came to the plate with one out and a runner on in the seventh and a ball hit down the first base line was called foul. During the ensuing replay, which confirmed the ruling, fans began chanting "Single! Single!"
Duffy then bounced into an inning-ending double play.
Bumgarner struck out Brandon Barnes in the second for his 1,000th strikeout, prompting a standing ovation. He finished with eight strikeouts and two walks.
Rockies: RHP Tyler Chatwood (Tommy John surgery) threw another bullpen session as part of his recovery from a second surgery. "He's in the process of building himself back up again," manager Walt Weiss said. "We've talked about having him back this year but there is no timetable." ... LHP Jorge De La Rosa (split middle finger on left hand) appears to be on target to make his next scheduled start in Oakland on Tuesday. "I thought his start would be in jeopardy," Weiss said. "It looks like it closed up in time."
Giants: RHP Tim Lincecum will need at least a week to recover from a contusion on his right forearm, the result of getting hit by a line drive Saturday. "He's sore," manager Bruce Bochy said. "It will serve him well to back off a little bit, and give him a break. With the injury, it's a no-brainer now." ... OF Hunter Pence played catch for the first time since returning to the DL with soreness in his left wrist.
Rockies: RHP David Hale (2-2, 5.86 ERA) gets the start Monday night when the Rockies open an interleague series in Oakland. He has allowed five earned runs in each of his last two starts. He is 0-2 with a 10.32 ERA in seven interleague games, including one start. He has never faced Oakland.
Giants: RHP Ryan Vogelsong (6-5, 4.05 ERA) gets the ball when San Francisco begins a three-game series at Miami on Tuesday night. He is 3-3 with a 1.89 ERA in 10 career appearances, including six starts, against the Marlins. That is his lowest ERA against an opponent he has faced more than three times.