The St. Louis Cardinals rallied in the ninth inning to back a strong start by Adam Wainwright in a 5-5 tie Tuesday with the Washington Nationals.

Trailing 5-2 in the ninth inning, the Cardinals scored three runs while down to their final out. Austin Dean crushed a two-run home run to put the Cardinals in striking distance, while José Rondón delivered the game-tying hit.

The rally backed a strong day from Wainwright, who opened the game with back-to-back strikeouts. He then forced a groundout from reigning batting champion Juan Soto, who was hitless in three at-bats against the right-hander. Wainwright’s lone mistake came in the second inning, when Kyle Schwarber launched a solo home run for the game’s first run.

The Cardinals tied it with a small rally in the fourth. Nolan Arenado led off with a walk, then the Cardinals loaded the bases on back-to-back singles from Paul DeJong and Tyler O’Neill. Yadier Molina drove in the Cardinals’ first run on a sacrifice fly, but the Nationals limited the damage to one run.

Wainwright stretched out to 76 pitches over six innings. He found a groove for a spring-best seven strikeouts and nine groundouts. Wainwright finished his day with another grounder from Soto, allowing only one earned run, two hits and one walk.

Génesis Cabrera took the mound in the seventh and pitched into some tough luck. Nationals first baseman Josh Bell led off with a grounder that hopped off second base. The next hitter, Starlin Castro, reached on a Cabrera fielding error.

Schwarber helped the Nationals take another lead. He hit a double off the center field wall, scoring the go-ahead run. Washington extended its lead to 4-1 in the seventh, adding two more from a Luis García double and a Victor Robles sacrifice fly.

The Cardinals gained some ground in the bottom of the inning when Max Moroff sliced an opposite-field single to cut the deficit to 4-2. The Nationals jumped to a three-run lead again in the eighth on a Josh Bell double.

After holding the Nationals scoreless in the ninth, the Cardinals wouldn’t go quietly. Justin Williams ripped a one-out double for the Cardinals’ first hit of the inning. Nationals pitcher Joe Ross, who tossed 4 2/3 innings in relief, was removed from the game with a 5-2 lead and one out away from a victory.

The Nationals called on Dakota Bacus to close out the game, a pitching change that proved vital in the comeback effort. His first opponent, Austin Dean, smacked a two-run home run that cut the Cardinals’ deficit to 5-4.

Moroff and John Nogowski kept hopes alive with back-to-back two-out walks. Rondón worked a full count, then hit a two-out, game-tying single.

The game ended when Edmundo Sosa grounded out to second base, stranding two runners and handing the Cardinals their fifth tie of spring training. They are 7-7-5 in Grapefruit League play.

Up next, the New York Mets pay a visit to Jupiter, Florida. The Cardinals will play their third straight game at Roger Dean Stadium. The game will air on FOX Sports Midwest at 12 p.m. CT.