ST. PETERSBURG, Fla. (AP) — Evan Longoria’s second homer of the game, a two-run shot off Takashi Saito with two outs in the bottom of the 13th inning, gave the Tampa Bay Rays a 4-2 victory over the Boston Red Sox on Tuesday night.

Longoria, who struck out four times, homered in the eighth off Daniel Bard, tying the score 2-all.

The Red Sox bullpen worked out of jams in the eighth, ninth and 10th innings, but couldn’t hold off the Rays a fourth. Boston squandered an opportunity to take the lead when Dustin Pedroia grounded into an inning-ending double play with the bases loaded in the 10th.

Michel Hernandez walked to start the 13th. After a sacrifice bunt and a groundout, Longoria hit his 23rd homer of the season off Saito (2-3) to end the 4 hour, 57-minute game.

Lance Cormier (2-1) gave up one hit in one inning for the win.

The third-place Rays remained 5½ games behind first-place New York in the AL East. The second-place Red Sox had their four-game winning streak stopped and fell 1½ games off the pace.

The Red Sox wasted a strong performance by Jon Lester, who allowed one run and three hits and struck out 10 in six-plus innings, holding the AL champions scoreless until the seventh. The left-hander hit Carlos Pena with his final pitch of the night, then watched the Rays trim a 2-0 deficit to one run with two singles off the bullpen.

Jason Bartlett drove in Tampa Bay’s first run with an infield single off Bard. Longoria made it 2-2, homering off the reliever on the first pitch of the eighth. The Red Sox then needed a break to get out of the inning without falling behind.

Bard, who hadn’t given up an earned over 14 innings of his last 12 outings, walked Ben Zobrist and compounded Boston’s trouble when he fielded Willy Aybar’s bunt and threw wildly past first base into the right-field corner for an error.

Zobrist and Aybar both circled the bases to score on the play, but were sent back to second and third because the ball rolled under an equipment bag in the Rays’ bullpen. Pena walked to load the bases with no outs, but Boston escaped when Bard struck out B.J. Upton and Manny Delcarmen retired pinch-hitters Gabe Gross and Pat Burrell.

Kevin Youkilis hit his 20th homer in the second inning and Pedroia connected for his seventh in the sixth for the Red Sox, who conclude a two-game series here Wednesday night before heading to New York for four games against the Yankees.

Matt Garza limited the Red Sox to three hits while walking two and striking out six in seven innings.

NOTES: Boston LF Jason Bay (mildly strained right hamstring) was out of the lineup for the second straight game since leaving Saturday’s win over Baltimore because of a cramp in the hamstring. He expects to play Wednesday. … Crawford swiped second and third in the first inning, hiking his major league-leading total to 51. It’s the fifth 50-steal season of his career, most among active players. … Rays manager Joe Maddon tweaked his batting order, using Bartlett as the leadoff man after the shortstop had three hits, walked once and drove in two runs in Monday’s win over Kansas City. Customary leadoff batter Upton was dropped to seventh. The move paid off, with Bartlett going 2 for 4 with two walks.

Only subscribers are eligible to post comments. Please subscribe or to participate in the conversation. Here’s why.

Use the form below to reset your password. When you've submitted your account email, we will send an email with a reset code.