NEW YORK — The Red Sox salvaged their AL wild-card lead Sunday when Jacoby Ellsbury hit a two-out, three-run homer in the 14th inning of the nightcap of a day-night doubleheader, lifting Boston over the Yankees 7-4.
The Red Sox rallied from a 3-0 deficit to snap a four-game skid and head into their final series with a one-game lead over the Rays.
Boston held a nine-game lead over Tampa Bay entering play Sept. 4 but has gone 5-16 since. Up by 11/2 games to start the day, the Red Sox nearly wasted that entire lead after losing the opener 6-2 despite Ellsbury's two homers. Combined with the Rays' 5-2 win over Toronto, the Red Sox went into the second game with a half-game lead.
Boston finishes in Baltimore, while Tampa Bay hosts the Yankees, who already have clinched the AL's best record and homefield advantage through the AL Championship Series.
"I hope we were breathing before — every other breath. It was a big win, but we've got to go down (today) and play well," Red Sox manager Terry Francona said.
Ellsbury homered off Scott Proctor after Darnell McDonald singled and Marco Scutaro walked.
Franklin Morales pitched two innings for the win. Felix Doubront, recalled on Sept. 1, finished the 5-hour, 11-minute game for his first save since August 2010.
In the opener, A.J. Burnett made his most impressive start in nearly three months and Jorge Posada hit a two-run homer for the Yankees. Ellsbury connected twice to become the first player in Red Sox history to reach 30 homers and 30 stolen bases in a season.
Desperate for a win in the second game, Francona used Jonathan Papelbon for a season-high 21/3 innings, bringing the closer in with the score tied on the road.
Typical of the bumbling baseball they've played while going 6-18 in September, the Red Sox made three more errors Sunday, several miscues on the basepaths and blew an opportunity to advance the runner in the 10th inning with a sacrifice. They had the leadoff runner reach in each inning from the sixth through the 10th in the nightcap.
Yet they still won.
Yankees manager Joe Girardi was ejected for the third time this season when he raced onto the field in the 13th to protect first baseman Nick Swisher and dispute a call after Tim McClelland called Dustin Pedroia safe. Replays show the diving Pedroia was out.
The Red Sox fell behind in the first inning for the third straight game in New York but rallied to take a 4-3 lead in the seventh.
The Yankees tied it, though, in the bottom half on a sacrifice fly by Chris Dickerson, the only New York player to start both games.
The Red Sox fell behind in the first, making their third error of the doubleheader and 17th in 12 games.
With two on against John Lackey, Mark Teixeira hit a drive off the top of the fence in right-center. Teixeira went for third on the throw home and was able to score when catcher Jason Varitek threw the ball into leftfield.
The Boston offense, meanwhile, woke up in the fifth after going 6-for-30 in the opener. Jed Lowrie hit a drive that hit off the wall in rightfield under the glove of a leaping Swisher for a triple. J.D. Drew, playing for the first time since July 19 because of a shoulder injury, singled him home for the first run off Ivan Nova in 15 innings.