Shane Victorino the go-ahead homer in the eighth a night after erasing a ninth-inning deficit to win. The Red Sox dug deep once more to record their fourth successive victory and strengthen their grip on the American League East.
The Yankees led at the end of the fifth but it was not enough as Boston's fearsome offence moved through the gears.
Napoli also doubled, singled and walked twice in a perfect night at the plate.
Omar Infante had six RBI and Andy Dirks went five for five as Detroit thrashed Kansas City 16-2.
Austin Jackson also drove in four runs to support starter Anibal Sanchez who recorded his 13th win.
Scott Feldman pitched a five-hitter and Chris Davis smacked his league-leading 48th home run of the year as Baltimore beat the Chicago White Sox 4-0.
Danny Valencia and Matt Wieters also homered for the Orioles, who stay in contention for the final AL wild-card place.
Oakland and Texas have identical 80-60 records atop the AL West - the A's beat Houston 7-5 while Texas went down 6-5 to the Los Angeles Angels.
Toronto scraped past Minnesota 6-5 while Tampa Bay went down 6-4 to Seattle.
Joey Votto emerged from a prolonged slump with a single and a two-run homer as Cincinnati remained in the hunt in the NL Central after edging out the Los Angeles Dodgers 3-2.
Coming into the contest hitless in his previous 13 at-bats, All-Star Votto reached base in all four plate appearances and took Dodgers pitcher JP Howell deep in the fifth inning.
Cliff Lee allowed one run over eight innings to help Philadelphia beat Atlanta 2-1. Cody Asche provided the offence with a two-run homer in the seventh.
Backed by Junior Lake's first career grand slam in the first inning, the Chicago Cubs beat Milwaukee 8-5.
Miami trounced Washington 7-0, St Louis overcame Pittsburgh 12-8, San Diego edged out Colorado 4-3 and San Francisco blanked Arizona 3-0.
In interleague play, play-off hopefuls Cleveland beat the New York Mets 8-1.