With Carlos Pena and Carl Crawford homering to back right-hander James Shields, the Rays won 5-3 Sunday night to keep pace with the New York Yankees and drop the third-place Red Sox 6½ games behind in the division and wild-card races.
Tampa Bay remains tied with the defending World Series champions, who beat the Chicago White Sox 2-1, for the seventh straight day.
"That's interesting," Rays manager Joe Maddon said after his team won for the 11th time in 15 games. "That's just the way it is. And, I expect the same kind of September. Back and forth, back and forth, back and forth."
Shields (13-11) won for the sixth time in eight starts, allowing three runs and seven hits over 6 2/3 innings. He walked one and struck out eight before turning over a one-run lead to a better-than-expected bullpen that's one of the reasons Tampa Bay has been able to keep up with the Yankees for the best record in baseball.
The Rays rebounded from losing the opener of the crucial weekend series to win two straight and improve to 10-5 against Boston. The season series concludes with three games at Fenway Park, where Tampa Bay is 5-1, Sept. 6-8.
The Red Sox crept within 4½ games of the Rays and Yankees by winning Friday's series opener. The Rays twice overcame one-run deficits in the late innings before winning 3-2 Saturday on Dan Johnson's solo homer in the 10th.
Boston Manager Terry Francona remains optimistic about the chances of hanging in the division and wild-card races.
"I hope so," Francona said. "It's the only way we can go."
Red Sox pitcher John Lackey agreed that the deficit is not insurmountable.
"We've got a lot more games than that," he said. "I'm not a math whiz, but I think it's doable."
Pena and Crawford both homered off Lackey (12-8). Pena hit a solo shot in the fourth and Crawford delivered a two-run shot that wiped out a 3-1 Boston lead in the sixth.
Johnson's RBI single snapped the 3-all tie later in the sixth. Evan Longoria drove in the final run charged to Lackey with a two-out single off Hideki Oakajima in the seventh.
Reliever Randy Choate got the final out of the seventh and Joaquin Benoit pitched a perfect eighth before Rafael Soriano sat the Red Sox down in the ninth to earn his major league-leading 39th save in 41 opportunities.
Pena has hit an AL-leading 141 homers since joining the Rays in 2007, one more than New York's Alex Rodriguez. He has a major league-leading 18 against Boston during the span, five more than A-Rod and Mark Teixeira.
The Red Sox countered with two runs in the fifth, with rookie Yamaico Navarro getting his first major league RBI and Marco Scutaro following with a sharp ground ball that hopped over the outstretched glove of Longoria, the Rays' third baseman, for a run-scoring single.
Shields escaped further damage in the fifth, getting J.D. Drew to ground into a force play and striking out hot-hitting Victor Martinez -- 8 for 13 with three homers in the series -- to end the inning. Daniel Nava's RBI single put Boston up 3-1 in the sixth.
Crawford's home run into the right-field stands made him the eighth player since 1900 to get at least 100 homers, 100 triples and 400 stolen bases in a career. The others are Ty Cobb, Tris Speaker, Lou Brock, Frankie Frisch, Kenny Lofton, Paul Molitor and Tim Raines.
"When you get into elite company like that, it feels real good," Crawford said. "You feel real proud about the stuff you've been able to accomplish. ... It just makes you want to see how far you can go."
Johnson's bases-loaded single snapped the tie, but a terrific throw to the plate by Boston center fielder Darnell McDonald stopped Pena from scoring from second and kept the Red Sox from falling behind by two runs.
Lackey allowed five runs and nine hits in 6 1/3 innings. The right-hander walked three and struck out seven.
- When Martinez singled with one out in the fourth inning, it gave the Red Sox catcher eight hits in the series. Tampa Bay had 11 as a team up to that point.
- Since allowing six homers in a loss to Toronto on Aug. 7, Shields has limited one over his last four starts. He still leads the AL in homers allowed at 29.
- Former Colorado OF Brad Hawpe, signed by Tampa Bay to a minor- league contract, will play his second game for Class A Charlotte on Monday. He's expected to join the Rays on Tuesday or Wednesday.