"Cole seems like he's focused and he's able to block it out," said Pence, who came to the Phillies in a mid-summer deadline trade with Houston last season. "Hopefully, he doesn't have to do this too much and we can turn this thing around."
Hamels (11-4), making his 100th career road start, scattered six hits and had seven strikeouts in his first win in three career outings at Coors Field. He was 0-1 with an 8.38 ERA at Colorado's hitter-friendly park coming into the game. Antonio Bastardo finished up with a 1-2-3 ninth.
Hamels, who was swamped with questions about his future when he went to the All-Star game, said he's doing his best to stay focused and not get caught up in all the trade chatter with the deadline looming at the end of the month. "I just have to go out and do my own business and make pitches and pitch in ball games every five days and I think that's all I can be accountable for," Hamels said. "It's nothing I'm going to focus on or worry about."
Drew Pomeranz (1-4) went five innings and allowed five runs on five hits in taking the loss, striking out five and walking two.
After dropping the opener, the Phillies took consecutive games from the Rockies for their first series victory since June 19-21, when they also took two of three from the Rockies at Citizens Bank Park. The Phillies, who trail in the NL East, were winless in their previous five series against Tampa Bay (1-2), Pittsburgh (2-2), Miami (0-3), the New York Mets (1-2) and Atlanta (0-3). However, they have kicked off the second half of the season on a positive note.
"We all have faith," Pence said. "We're feeling good and were going to keep pushing."
Up 2-0, the Phillies pulled in front 5-0 in the fifth when Pence connected for his team-leading 17th homer. Jimmy Rollins hit a two-out single and took second on an errant pickoff throw by Pomeranz before Shane Victorino drew a walk. Pence worked the count against Pomeranz to 2-2 and then jumped on a 79 mph curveball he sent 20 rows deep into the left field bleachers.
"He didn't finish that breaking ball pitch and he hung it," Rockies manager Jim Tracy said. "That's what Hunter Pence does when you hang breaking balls in the middle of the plate. He hits them out of the ballpark."
The Rockies, who hadn't had a baserunner reach second since Dexter Fowler led off the bottom of the first with a single and advanced on a sacrifice, broke up Hamel's bid for a fifth career shutout in the sixth inning. Hamels issued a one-out walk to Marco Scutaro, his only one of the day, and Carlos Gonzalez followed with an RBI triple that went to the wall in left-center field. Hamels prevented further damage by striking out Ramon Hernandez and getting Michael Cuddyer to ground out.
"He was throwing his pitches for strikes," the Rockies Tyler Colvin said of Hamels. "He was working that changeup in there any time in the count and keeping us off balance."
Victorino got the Phillies' offense going in the first by tripling to center. One out later, Carlos Ruiz brought him home with a single to left. The Phillies got another run in the fourth when Ruiz doubled, moved to third on Ty Wigginton's groundout and scored on Placido Polanco's sacrifice fly.
NOTES: RHP Joe Blanton (7-8) will pitch Monday night's series opener at Los Angeles for the Phillies... Phillies ace Roy Halladay is set to come off the 15-disabled list and start Tuesday night's game against the Dodgers... Pence's homer was the seventh hit in his last 16 at bats with runners in scoring position (.437).