WASHINGTON — Ender Inciarte snapped a ninth-inning tie with a two-run triple, and the Atlanta Braves beat the Washington Nationals 3-1 Tuesday night to earn a doubleheader split.

In the opener, Bryce Harper and Ryan Zimmerman hit consecutive homers to spark a four-run fourth inning that carried Washington to an 8-3 victory.

Seeking to blunt the momentum of the surging Nationals, Atlanta shook off a strong pitching performance by Max Scherzer before striking against the Washington bullpen in the second game of the day-night doubleheader.

Freddie Freeman and Nick Markakis singled off Kelvin Herrera (1-2) before Inciarte hit a liner down the first-base line. The ball bounced off a low barrier in foul ground and momentarily eluded Harper, who had no options by the time he picked it up in right field.

That was the final pitch thrown by Herrera, who left after a visit from Washington’s trainer.

Jesse Biddle (3-0) pitched 12/3 innings and A.J. Minter got three outs for his ninth save.

The defeat ended Washington’s run of nine wins in 12 games. The Nationals are chasing first-place Philadelphia and Atlanta in the NL East.

Atlanta has won seven of nine.

The second game developed into a pitcher’s duel between Scherzer, seeking to win his sixth straight start, and Sean Newcomb, who allowed one run and five hits over six sharp innings.

Scherzer gave up one run and four hits in seven innings with six strikeouts. He remains unbeaten since July 2.

CARDINALS 3, MARLINS 2: Streaking Matt Carpenter hit his 30th home run, a tiebreaking drive in the eighth inning that lifted St. Louis to a win at Miami.

Carpenter connected for the fourth time in five games and increased his career high for home runs. He also extended his streak of reaching base safely to 26 games, the longest active string in the majors.

Carpenter, who has won two of the last three NL Player of the Week awards, sent a shot off Elieser Hernandez (2-6) into the Cardinals bullpen in right field. Several St. Louis relievers celebrated with their arms in the air.

Paul DeJong hit a tying, two-run homer in the seventh for the Cardinals. Marcell Ozuna had a pair of hits and is 5 for 8 in his first two games at Marlins Park since being traded by Miami to St. Louis in the offseason.

Miles Mikolas (12-3) pitched seven innings, allowing two runs and five hits.

AMERICAN LEAGUE

RAYS 4, ORIOLES 3: Willy Adames hit a solo home run with two outs in the ninth, giving Tampa Bay a win at home.

Sergio Romo (2-2) got the win after retiring two batters in the ninth, helping the Rays break a three-game losing streak.

Tim Beckham and Trey Mancini homered and Alex Cobb pitched seven innings for Baltimore.

Cobb, attempting to win consecutive starts for the first time with the Orioles, gave up only two hits after the first inning and retired the last 10 batters he faced against his former team.

Cobb left with a 3-1 lead, but the Rays tied it in the eighth without getting a hit. Three walks and a wild pitch by reliever Evan Phillips and a throwing error on first baseman Chris Davis helped the Rays score two unearned runs.

INTERLEAGUE

ASTROS 2, GIANTS 1: Tyler White hit a two-run homer in the eighth inning and the Houston Astros pulled off a late rally for the second straight game to beat host San Francisco.

The win followed the Astros’ 3-1 victory Monday night in which Marwin Gonzalez hit a three-run homer with two outs in the ninth.

This time, the AL West leaders again trailed 1-0 when Gonzalez doubled and White hit a high, arching shot to left field off Ray Black (1-1).

Houston has hit 13 home runs in its last eight games. The Astros have won six of seven and the Giants have lost four of five.

CUBS 5, ROYALS 0: Mike Montgomery allowed five hits over six-plus innings, David Bote drove in a career-high three runs and Chicago won in Kansas City, Missouri.

Montgomery (4-4), who the Royals drafted in the first round in 2008, picked up his first win since June 29.

Montgomery is 3-0 with a 0.40 ERA in four appearances against the Royals.