The Braves fell behind 4-1, giving up a two-run homer to Matt Holliday and two more RBI to a most unlikely hitter: pitcher Chris Carpenter, who had a run-scoring single and the second homer of his career batting in the eighth spot.
But Carpenter (15-6) couldn't back up his good work at the plate. The Braves closed to 4-2 in the fourth on Brian McCann's run-scoring single, then knocked out the St. Louis starter in the sixth.
Atlanta won for just the third time in nine games and remained one game behind NL East-leading Philadelphia, which beat the New York Mets 8-4. St. Louis began the night five games behind Cincinnati in the NL Central.
Pinch-hitter Brooks Conrad got the big inning started with the first of four consecutive hits off Carpenter. Jason Heyward yanked an RBI single to right, and Martin doubled to tie the game at 4.
McCann followed with a deep fly ball to right that would have brought in a run because Heyward was tagging, but it wound up driving in both runners when Jay dropped the ball just short of the wall. McCann rumbled all the way to third and trotted home on Derrek Lee's run-scoring single.
That wasn't the only break for the Braves. Conrad appeared to be picked off at second on a throw from catcher Yadier Molina, but umpire Bill Welke called the runner safe. Even Conrad looked a bit surprised by the call. The tag appeared to get him on the right shoulder just before he scrambled back to the bag.
Carpenter was lifted after Lee's hit, having failed to get an out in the sixth. He was charged with six earned runs and eight hits. Melky Cabrera added a sacrifice fly before Conrad, batting for the second time, hit a flyout that finally ended the inning.
St. Louis scored a pair of runs off Jonny Venters in the seventh, but Takashi Saito and Billy Wagner closed out the Cardinals, with Wagner earning his 33rd save in 40 chances. Atlanta won its major league-leading 50th home game.