BOSTON (AP) — Jon Lester matched his season high with eight strikeouts and overcame homers by Wil Myers and Evan Longoria as the Boston Red Sox remained in first place with a 6-2 win over the Tampa Bay Rays on Tuesday night.

The Red Sox moved 1½ games ahead of the Rays in the AL East and stayed atop the division for the 58th consecutive day.

The loss ended the Rays’ six-game winning streak and was just their third in 21 games, a surge that began when they were in fourth place, trailing the Red Sox by seven games.

Boston is 3-4 since its four-game winning streak.

Lester (9-6) gave up two runs and seven hits with no walks in 6 1-3 innings. He is 3-6 with a 5.97 ERA since starting the season 6-0 with a 2.72 ERA. Four Red Sox pitchers combined for 13 strikeouts.

Roberto Hernandez (5-11) allowed three runs in five innings and tied R.A. Dickey for the second-most losses in the AL. But it was the 28th time in Tampa Bay’s last 31 games that its starter gave up three runs or fewer.

Boston led 3-2, then scored three runs in the eighth on an RBI single by Stephen Drew and a two-run single by Jose Iglesias.

Myers’ fifth homer of the season on the first pitch of the second inning gave the Rays a 1-0 lead. The Red Soxtied it in the bottom half on a run-scoring single by Mike Carp.

They went ahead 2-1 in the third on a double steal. Shane Victorino led off with a double and went to third on a flyout by Daniel Nava. Dustin Pedroia was hit by a pitch, then stole second as catcher Jose Molina threw down and Victorino scored.

The Red Sox had left runners at third base in three straight innings before Pedroia gave them a 3-1 lead with a sacrifice fly in the fifth.

The Rays got another leadoff homer off Lester in the sixth when Longoria hit his 21st on the second pitch, cutting the lead to 3-2.

NOTES: Myers missed the previous two games with a sore left wrist. He is 16 for 32 in his last eight games. … Rays 1B James Loney’s single in the second was the 1,000th hit of his career. … Pedroia was the only RedSox batter who went hitless. … Boston is 10-4 against Tampa Bay and has clinched the 19-game season series. The last time the Red Sox won the season series over the Rays was 2007. … Alex Torres pitched two scoreless innings and has allowed one run in 30 1-3 innings for the Rays. … David Price (4-5) pitches for the Rays against Felix Doubront (7-3) in the third game of the four-game series. … Boston CF Jacoby Ellsbury got the night off. He leads the majors with a .370 batting average since May 26.