Hellickson (5-1) gave up two first-inning runs in six innings and two hits. The right-hander retired 16 of the last 17 batters he faced, yielding only a walk and threw 84 pitches.
Hellickson exited after his double gave Philadelphia a 4-2 lead. He appeared to hurt himself swinging of running out of the batter's box.
With Hellickson out, Pat Neshek, Joaquin Benoit and Hector Neris held the Pirates at bay, combining on three scoreless innings.
Cameron Rupp's opposite field, three-run homer in the ninth provided insurance.
Hellickson's showing helped the Phillies win for only the fourth time in 19 games since April 29. Hellickson was a major culprit of the skid as he was 0-1 with a 7.90 ERA in his last three starts after going 4-0 with a 1.80 ERA in April.
Friday's outing was more April-like against the Pirates although he encountered trouble at the start, not all of it his fault.
Josh Harrison opened the game with a single and scored on Josh Bell's double. Bell took third on a David Freese groundout before scoring on a defensive miscue by the Phillies.
The inning appeared over when shortstop Freddy Galvis fielded Francisco Cervelli's grounder. His low throw to first got past Tommy Joseph and allowed Bell to score the Pirates' second run.
After the early Pittsburgh threat, Hellickson was superb. He ended the first by getting Jose Osuna on a groundout and only allowed a walk to Andrew McCutchen in the fourth
The Phillies broke through in the third when Pirates starter Trevor Williams (2-3) gave up a leadoff double to Galvis and walked Hellickson after Rupp grounded out. Cesar Hernandez ripped a single up the middle to score Galvis.
Philadelphia took the lead in the sixth.
Hernandez drew a leadoff walk and Daniel Nava flicked a soft double down the left-field line. Aaron Altherr then lined a shot off Williams' leg that turned into an out at first base, scoring Hernandez.
Joseph's sacrifice fly then sent Nava home to put Philadelphia ahead, 3-2. Hellickson's double in the seventh of Josh Lindblom scored Maikel Franco with the fourth run and Rupp capped the scoring by homering off Tony Watson.
NOTES: Pittsburgh claimed RHP Jhan Marinez off waivers from the Milwaukee Brewers. Marinez was 0-2 with a 5.40 ERA in 15 appearances for Milwaukee before being designated for assignment on Monday. ... Philadelphia OF Daniel Nava left the game with left hamstring tightness. ... The Phillies recalled RHP Adam Morgan from Triple-A Lehigh Valley.