Hamels (4-5) won for the second time in three starts, giving up one run, striking out nine and walking none. He threw 71 of 95 pitches for strikes.
Rollins’ 12th homer, coming off reliever Shae Simmons (1-1), made it 2-0 in the seventh.
Atlanta, which had a three-game winning streak snapped, cut its deficit to 2-1 in the seventh inning on Chris Johnson’s RBI double.
Jonathan Papelbon earned his 21st save in 23 chances, needing only five pitches to retire Andrelton Simmons on a groundout, Freddie Freeman on a lineout, and Justin Upton on a popup.
Grady Sizemore reached base four times, going 3-for-4 and scoring on Rollins’ homer.
The only baserunner Hamels allowed through the first 4 2/3 innings was Jason Heyward, who was hit by a pitch in the second. Tommy La Stella got the first hit off Hamels, a double in the fifth.
Hamels made 50 of his first 65 pitches for strikes before pinch-hitter Tyler Pastornicky singled in the sixth.
Braves starter Aaron Harang pitched six scoreless innings, allowing five hits and three walks with five strikeouts. The right-hander, who had won his last four starts, has a 2.18 ERA in his past five outings.
Hamels, 3-3 with a 1.78 ERA in nine road starts this year, received a no-decision in Atlanta on June 16 despite pitching seven scoreless innings in Philadelphia’s 13-inning victory.
Hamels improved to 15-8 with a 3.34 ERA in 31 starts and one relief appearance against the Braves. Ben Revere pinch-hit for him in the eighth.
Phillies manager Ryne Sandberg unsuccessfully challenged that Johnson was thrown out at second base in the seventh. Johnson, who drove in Upton from second, stretched a single into a double by beating Chase Utley’s tag attempt.
n NOTES: In 117 career games at Turner Field, Rollins has 11 homers and 45 RBIs. ... Simmons gave up two hits and two runs and got only two outs. ... Phillies LHP Cliff Lee, on the disabled list since May 20 with a strained elbow, is scheduled to start Monday at home against San Francisco. ... Braves C Evan Gattis, on the DL since July 1 with a bulging disc in his back, is expected to return from a rehab assignment with Triple-A Gwinnett next week against Miami. ... Atlanta optioned struggling LHP Luis Avilan to Gwinnett and purchased the contract of LHP Chasen Shreve from Double-A Mississippi. Shreve became the seventh Braves player to make his major league debut this year when he struck out Ryan Howard to end the seventh. ... Phillies C Carlos Ruiz, on a rehab assignment with Single-A Clearwater, went 1-for-3 with a walk, a stolen base and scored two runs on Friday. Ruiz has been sidelined since June 27 with concussion symptoms. ... The Braves’ Aug. 10 home game with Washington has been moved from 1:30 p.m. to 8:07 p.m.