A strikeout with the bases loaded by reliever Boone Logan in the fifth inning sparked the New York Yankees to a come from behind 3-2 win over the Boston Red Sox at Fenway Park on Friday.

The win was just New York's second in 10 attempts against Boston this season, but it moves the Yankees ahead of the Red Sox by a game at the top of the American League East.

Logan entered the game trailing 2-0 with the bases loaded and two outs in the bottom of the fifth and struck out Adrian Gonzalez, the league's batting leader, to quieten the Red Sox.

New York's offense responded in the sixth inning with three runs and two walks against Red Sox starter Jon Lester, who was in top form through the first five innings.

Boston went ahead when Marco Scutaro scored in the third inning on an RBI double by Jacoby Ellsbury and David Ortiz hit a solo home run in the fourth to give the Red Sox a 2-0 lead.

Former Red Sox pitcher Bartolo Colon started for the Yankees and allowed two runs on six hits in four and 2/3 innings before giving way to Logan who earned the win to improve to 3-2 this season.

Logan and three relievers delivered the lead to Mariano Rivera who pitched a clean ninth inning for his 29th save.