Tyler O'Neill hit a tiebreaking homer, Cardinals relievers combined for five scoreless innings, and St. Louis salvaged a split of its four-game series against the Los Angeles Dodgers with a 2-1 win on Thursday.
The Cardinals climbed within three games of the San Diego Padres for the final NL wild-card spot, while the Dodgers fell 2 1/2 games behind the NL West-leading San Francisco Giants.
O'Neill's fifth-inning drive off Phil Bickford (3-2), his 25th homer this season, barely cleared the left field wall, inching past the outstretched glove of Steven Souza Jr.
The homer made a winner out of Alex Reyes (6-8), who pitched two scoreless innings in his fifth appearance since being demoted from the closer's role.
T.J. McFarland and Luis Garcia combined for two scoreless innings to bridge the gap to Giovanny Gallegos, who earned his sixth save with a perfect ninth.
Jon Lester (5-6, 4.89) will start the opener of a pivotal three-game home series against the wild card-contending Cincinnati Reds and RHP Tyler Mahle (11-5, 3.76) on Friday night.