Gerrit Cole shut down eight of the nine hitters in the Red Sox lineup - good enough to lead the New York Yankees to a 6-5 victory over Boston on Thursday night.

And then there was Rafael Devers.

The Red Sox third baseman made a final push to be added to the AL All-Star roster by homering twice off the Yankees ace, delivering two of Boston's five hits and all five of the RBIs. In his career, he has a .304 average with six home runs in 23 at-bats against Cole.

"I'm open for suggestions," the Yankees right-hander said to reporters afterward. "It's pretty wild. He's just been able to hit every(thing), there hasn't been a miss-hit. Like, roll over one time. Like, line out one time.

"You're supposed to fail seven out of 10 times in this gig. I don't know what the deal is," he said. "We'll just have to just keep at it, man."

Josh Donaldson homered for the second straight game, hitting a grand slam in the third, and Aaron Hicks homered on the very next pitch to stake Cole to a 5-0 lead. Hicks also tripled in the fifth and scored to make it 6-2 before Devers' second homer brought Boston within one run and sparked the heartiest "Yankees suck!" chant of the night.

"It's great pitcher against a great hitter," Yankees manager Aaron Boone said. "And he's had some success, obviously."

Entering the game tied for second in the AL East - but 14 games behind the first-place Yankees - the Red Sox fell behind 5-0 in the third before Devers' two-run shot in the bottom half. The Yankees led 6-2 in the fifth with Devers due up again - time for a meeting on the mound.

"We said 'Homer doesn't beat us right here. So, you know, let's just go make our pitches,'" Cole said. "And, you know, we made our pitches and gave up a homer, but they didn't beat us."

In all, Cole was charged with five runs on five hits and three walks while striking out seven. Three relievers shut the Red Sox down from there, with Clay Holmes pitching the ninth for his 16th save.

Red Sox starter Josh Winckowski (3-3) gave up six runs on six hits and five walks in five innings.

The Yankees loaded the bases in the third inning of a scoreless game when No. 9 hitter Joey Gallo led off with a walk, Gleyber Torres singled and stole second and then, with two outs, the Red Sox pitched around Giancarlo Stanton to face Donaldson with the bases loaded.

He lined a 429-foot homer to center for his sixth career grand slam, then Hicks sent the next pitch 385 feet to right.

In the fifth, Hicks lined one over Jackie Bradley Jr.'s head and off the wall, away from the Red Sox right fielder. He scored to make it 6-2 when first baseman Franchy Cordero misplayed an infield popup into a double (that was changed to an error and back to a double).

VOTE RAFFY

Devers now has 12 career multihomer games.

He is campaigning to be the first Red Sox third baseman to make back-to-back All-Star Games since Wade Boggs played in seven straight from 1986-92. In voting that ends Friday at 2 p.m., Devers led Cleveland's José Ramírez 59% to 41%.

HALF-STAFF

The U.S. flag in center field and behind home plate flew at half staff in memory of the victims of the Fourth of July shooting in Highland Park, Illinois, that killed seven and wounded dozens of others.

TRAINER'S ROOM

Yankees: OF Aaron Judge got a day off for lower body tightness.

Red Sox: Placed RHP Tyler Danish on the 15-day injured list with a right forearm strain. To fill his spot on the roster, the club selected RHP Michael Feliz from Triple-A Worcester.

UP NEXT:

Yankees left-hander Jordan Montgomery (7-3) will pitch the second game of the four-game series, perhaps against Boston righty Connor Seabold (0-1).

More From 92.9 The Ticket