In his last two starts Samardzija (6-9) had given up 14 runs on 18 hits in 10 2/3 innings. He turned things around against the Rockies, limiting them to a run on four hits with six strikeouts.
The only Colorado run came on a homer by Dexter Fowler in the fourth that created a 1-1 tie.
Chicago finally took the lead for good in the seventh on an RBI double by Anthony Rizzo and the Cubs added a score in the ninth on another run-producing double by Darwin Barney.
The loss went to Edgmer Escalona (1-3), the second of four Colorado pitchers who gave up Rizzo's double in the seventh.
Notable deaths of 2014 [PHOTOS]