NEW YORK -- Sweat was streaming down CC Sabathia's face to the point where he said he couldn't see. He stomped around the mound, shouted and swore encouragement to himself.

Oh, he also had a little extra kick on his fastball.

Sabathia had what he acknowledged was his best outing in a trying season Thursday night, pitching six intense innings and helping the New York Yankees beat the Boston Red Sox 2-1 behind Jacoby Ellsbury's slump-busting, tiebreaking homer.

"I was all fired up," Sabathia said.

Alex Rodriguez had an RBI double, and Justin Wilson (4-0) struck out three batters in the seventh to help the Yankees take two of three from the last-place Red Sox.

The AL East-leading Yankees next face a pair of Cy Young Award winners, R.A. Dickey and Toronto newcomer David Price, when they take on the streaking Blue Jays in a key weekend series. The division rivals, separated by 4½ games, play the first of 13 remaining games against one another Friday night.

"We know how explosive they are," Yankees manager Joe Girardi said. "We just have to make pitches."

Dellin Betances gave up a hit in the eighth. Andrew Miller put two on in the ninth but struck out Rusney Castillo to remain perfect in 24 save chances.

Ellsbury connected with two outs in the seventh off Eduardo Rodriguez (6-4), who beat the Yankees once this year.

Ellsbury, a former Red Sox center fielder, was in a 3-for-23 slump entering Thursday. He was batting .322 when he returned from the disabled list on July 8, but his average had dipped to .277 entering Thursday's game.

"I've been feeling pretty comfortable at the plate," Ellsbury said. "I just knew it was a matter of time."

Sabathia left his previous start with dehydration, wilted by the Texas heat. He was ornery in this outing, yelling at plate umpire Rob Drake over a called ball early on and shouting while giving a fist-pumping shimmy after striking out David Ortiz on a 94 mph two-seam fastball with the bases loaded to end the fifth.

Sabathia's fastball this season was averaging just 90.1 mph, according to fangraphs.com.

"He threw me some good pitches," Ortiz said. "Tonight was the best I have seen him in a while. He was locating his pitches well."

Sabathia had just walked Xander Bogaerts following Castillo's run-scoring single that ticked off the glove of diving shortstop Didi Gregorius to tie the score at 1-1. Castillo's hit came right after Sabathia walked .100 hitter Jackie Bradley Jr.

Eduardo Rodriguez intentionally walked Alex Rodriguez to load the bases in the bottom half, but Mark Teixeira and Chris Young popped out.

Pitching on an extra day of rest, Sabathia stalked around the mound and used pinpoint control to strike out eight. He yielded three hits and three walks after allowing five runs in each of his previous two starts.

At 35, Sabathia said he thinks he might be better off pitching with more time between starts.

"I hated the rest before, but, just to get my body in order, whatever rest they give me I'll take," he said. "If not I'll take the ball when they need."

TRAINER'S ROOM

Red Sox: At his request, OF Mookie Betts saw concussion specialist Dr. Michael Collins in Pittsburgh. "As far as I know, reports were good," general manager Ben Cherington said. Betts is expected to join the Red Sox in Detroit this weekend, but there is still no target date for his return. ... Cherington said top prospect Brian Johnson, a first-round draft pick in 2012, has inflammation around his pitching elbow but there is "no evidence that there is anything going on around the ligament."

Yankees: Brian McCann (stiff knee) was out of the starting lineup for a second straight night, but Girardi said the catcher could've played. He said McCann is day-to-day and it shouldn't be a long absence.

ICE COLD

Alex Rodriguez, Brett Gardner and Teixeira took the ice bucket challenge before batting practice. Kids from Harlem RBI had the honor of pouring the water. A-Rod held his nose when he was doused.

OPPOSITE DIRECTIONS

The Yankees are 8-0-1 in their past nine series. Boston has lost nine of 10 on the road.

UP NEXT

Red Sox: Joe Kelly (3-6) starts the series opener against Detroit. The right-hander has allowed at least four runs in each of his past four starts.

Yankees: Nathan Eovaldi (11-2) makes his first start against Toronto's potent offense. New York faces a second knuckleballer this week in Dickey (6-10) after being held to a run in eight innings by Boston RHP Steven Wright on Wednesday.