The Phillies manufactured a run in the bottom of the eighth inning to squeak by the Washington Nationals, 4-3, at Citizens Bank Park on Tuesday night.
After breezing through the first six innings, Cole Hamels was hit hard in the seventh and eighth innings as he let a 3-0 lead get away.
The Phillies used an error, a stolen base and two fly balls to push home the go-ahead run in the eighth.
The Phillies are 6-2 on this homestand and they have taken two in a row from the Nationals, who lead the NL East and had won 12 of 13 coming into the series.
Washington has lost back-to-back games for the first time since Aug. 5.
Starting pitching report
Hamels cruised through the first six innings, allowing three hits and no runs over that span. He took a 3-0 lead into the seventh and things began to fall apart when he gave up four hits, a walk and two runs as the Nats cut the Phillies' lead to 3-2. Hamels' strong start totally unraveled when he allowed a game-tying leadoff homer (on his 84th pitch of the night) to Asdrubal Cabrera in the eighth.
Manager Ryne Sandberg pulled Hamels after the home run. The pitcher appeared to be quite perturbed as he left the game. He executed a quick handoff of the ball to Sandberg on the mound and left the field.
Washington lefty Gio Gonzalez allowed three runs, all on homers, over six innings.
Ken Giles struck out the side after Hamels left and got the win.
Jonathan Papelbon earned save No. 33 on the season. It was his 100th with the Phillies.
Tyler Clippard took the loss.
At the plate
The Phillies took a 3-0 lead on a two-run home run by Freddy Galvis in the fifth and solo homer by Darin Ruf in the sixth. Galvis' homer was preceded by a triple by Grady Sizemore.
Ben Revere scored the go-ahead run in the eighth. He reached on an error by shortstop Ian Desmond, stole second, went to third on a fly ball to right by Jimmy Rollins and scored on a sacrifice fly by Carlos Ruiz.
The Nationals used four singles and a walk against Hamels to cut the Phils' lead to 3-2 in the seventh. Cabrera then led off the eighth with a solo homer against Hamels to tie the game.
Pitcher Miguel Alfredo Gonzalez is in line to join the big club next week (see story).
Kyle Kendrick (6-11, 4.93) will oppose Doug Fister (12-4, 2.38) in the series finale Wednesday night.