Brett Pill hit a pair of triples, including a ahead two-run triple in the eighth to give San Francisco a 6-5 win over game set.
The win cut San Francisco's deficit in the NL West to five games back of Arizona, which lost to San Diego on Saturday.
"It's pretty simple at this point. Obviously we need some help," said Giants manager Bruce Bochy.
Carlos Beltran went 3-for-5 with an RBI and a run scored for the Giants, who have won seven straight to get back into the playoff chase.
Eric Surkamp started on the mound, but was pulled after 4 2/3 innings as he had walked six and given up a run on three hits with four strikeouts. Waldis Joaquin (1-0) earned the first win of his career for getting the final two outs of the seventh inning.
Santiago Casilla worked a shaky ninth inning for his fifth save of the season.
"You have to give our young kids a lot of credit for the effort they put out there tonight," said Colorado manager Jim Tracy. "We battled and scratched back, just came up a little short."
Drew Pomeranz gave up just two runs on four hits with two walks and five strikeouts over 5 2/3 innings. Huston Street (1-4) gave up four runs -- three earned -- while recording just one out in the eighth to take the loss.
Trailing by a run in the eighth, the Giants went ahead with a four-run frame.
Street started the inning on the mound and Andres Torres greeted him with a single. Jeff Keppinger then reached base on a Street throwing error. Beltran then doubled home a run and, after Mark DeRosa struck out, Pill brought home two more with his second triple of the game. Aubrey Huff later reached on a fielder's choice to score Pill for a 6-3 lead.
After Sergio Romo worked out of a jam in the eighth, Casilla came on for the ninth and got the first out, but then gave up a single to Seth Smith and Ty Wigginton worked a walk. Ellis then hit an opposite-field double to score a run and put the tying run on second base. Rosario followed with a groundout to short that scored Wigginton, but Hector Gomez struck out to end the game.
An RBI single from Eric Surkamp in the second inning put the Giants on top, but the Rockies tied it in the fifth when Pacheco singled home Dexter Fowler, who had walked and stolen second.
San Francisco went back on top in the sixth when DeRosa walked and, after Matt Belisle took over for Pomeranz, Pill tripled for a 2-1 lead.
Fowler, though, came through for the Rockies in the sixth when he hit a two- run single for a 3-2 lead.
The winning streak matches a season-high for the Giants...Ellis has a 10-game hitting streak...San Francisco has won 10 of the 14 games against Colorado this season.