ST PETERBURG, Florida (Reuters) - Boston pitcher Jon Lester won a pitchers' duel against David Price to lift the Red Sox to a vital 3-1 victory over the Tampa Bay Rays on Friday.

The win allowed the Red Sox to move to within 4 games of the Rays in the tight AL East.

The Rays remain tied with the New York Yankees for the division lead after the Bronx Bombers lost 9-4 to the Chicago White Sox in a late game.

Lester allowed just two hits and one unearned run in seven innings while striking out 10 batters, despite walking five batters and throwing three wild pitches, to earn his 14th win of the season.

"He (Lester) was, I thought, overpowering when he needed to be," Rays third baseman Evan Longoria told reporters.

Price allowed three runs on 10 hits while striking eight, also in seven innings.

Victor Martinez powered the Red Sox offense with two solo home runs, and David Ortiz led off the fourth inning with a double and later scored on an RBI single by Jed Lowrie.

"Home runs, they're just there," said Martinez, who has 12 of them on the season.

"Like I say, you just worry about making good contact and whatever happens, happens. I don't really think about hitting homers and stuff like that. I don't see myself as a home run hitter, and that doesn't really bother me."

The Rays run was scored with quite a bit of help from the Red Sox. Jason Bartlett reached first base on a throwing error and after advancing to second base on a single, two wild pitches by Lester allowed him to score.

(Reporting by Mike Mouat in Windsor, Ontario; Editing by John O'Brien)