Jose Lobaton

Tampa Bay's Jose Lobaton, center, celebrates with his teammate after hitting a walk-off home run in the ninth inning of the Rays' 5-4 win over the Boston Red Sox in Game 3 of the American League division series Monday. (Chris O'Meara / Associated Press / October 7, 2013)

ST. PETERSBURG, Fla. — The Tampa Bay Rays are still afloat in the AL division series.

Jose Lobaton hit a solo home run with two outs in the bottom of the ninth inning into the giant fish tank beyond the center-field wall, and Tampa Bay staved off elimination once again by beating the Boston Red Sox, 5-4, Monday night.

The Rays cut Boston's lead in the best-of-five series to 2-1. Game 4 is Tuesday night at Tropicana Field, with Jake Peavy starting for the Red Sox against Jeremy Hellickson.

Tampa Bay took a win-or-go-home game for the fourth time in nine days. The Rays did it with an unlikely stroke as Lobaton, who came off the bench late in the game, connected against Red Sox closer Koji Uehara.

"It's unbelievable. It's something you can't explain," Lobaton said. "We never give up. We're going to keep fighting."

Back home after two weeks on the road, the Rays gave a sellout crowd of 33,675 little to cheer until Evan Longoria homered on his 28th birthday. Longoria's three-run shot off Clay Buchholz with two outs in the fifth rallied Tampa Bay to a 3-all tie.

Pinch-hitter Delmon Young, who has a penchant for driving home key runs in October, put the Rays ahead, 4-3, with an RBI grounder in the eighth.

The Red Sox tied it in the ninth against Rays closer Fernando Rodney. Dustin Pedroia's RBI grounder made it 4-all.

Rodney got the win when Lobaton homered to right-center, into the 10,000-gallon tank where cownose rays swim around.

Uehara did not give up a home run in his final 37 regular-season appearances.

The Rays won three must-win road games in three cities over four days just to get into the division series, so they felt good about their chances of coming back against the Red Sox.

Especially with Alex Cobb on the mound. The right-hander beat Cleveland, 4-0, in the AL wild-card game last Wednesday and has been one of the consistent pitchers in the majors since August 2012.

The Red Sox were just as confident about the prospect of closing out the series.

Buchholz, limited to 16 starts this season because of a neck strain that landed him on the disabled list for three months, beat the Rays twice this year while allowing no runs and five hits in 13 innings. He also entered his second career postseason appearance with a 2.26 earned-run average in nine career starts at Tropicana Field.

Cobb settled down after a shaky first inning, in which he gave up a leadoff single to Jacoby Ellsbury, hit a batter with a pitch and walked David Ortiz. But the Red Sox got only one run out of it, when second baseman Ben Zobrist made a throwing error while trying to turn a double play.

Cobb, celebrating his 26th birthday, retired eight in a row before walking Ortiz leading off the fourth. Mike Napoli followed with a single for the second hit off Cobb, yet Boston was unable to take advantage.

Ortiz tagged and went to third on Daniel Nava's fly ball, then was nearly caught too far off the bag when Jarrod Saltalamacchia struck out and catcher Jose Molina threw to third base trying to pick off Ortiz. The inning ended with Stephen Drew hitting a grounder back to Cobb.