ST. PETERSBURG, Fla. — Austin Meadows hit a two-run single, and the Tampa Bay Rays held off the New York Yankees 5-3 for a split of seven-inning games in a doubleheader Saturday.

The Yankees won the opener 8-4 as ace Gerrit Cole came within one strike of earning his 20th straight regular-season win.

Cole, who had won his first three starts since signing a $324 million, nine-year contract in the offseason, took a 5-0 lead into the fifth inning but gave up three runs with two outs and was pulled because of a high pitch count.

In the nightcap, the Rays used six pitchers during a bullpen game. Aaron Judge, who hit his eighth home run of the season in the opener, flied out with a runner on base to end it.

"We're still not rolling but this was encouraging," Tampa Bay manager Kevin Cash said. "We had some pretty good at-bats against Gerrit."

Lefty-swinging Mike Ford hit for Yankees slugger Giancarlo Stanton against lefty Jalen Beeks in the sixth inning of Game 2 with two on and no outs. Stanton, who also homered in the first game, exited with tightness in his left hamstring.

"It was when he moved up on the wild pitch (in the fourth), that's where (it) tightened up on him." Yankees manager Aaron Boone said. "We're going to get an MRI, but it does look like an IL situation."

Stanton, limited to 18 games last season due to injuries, was hurt during spring training this season and rehabbed during the shutdown at the Yankees' complex in Tampa, Florida.

"Hurting for him, period," Boone said "I know what he's done to be here. Obviously, his play speaks for itself. So hopefully it's something that doesn't keep him down too long."

DJ LeMahieu got the Yankees within 5-3 on a two-run single in the seventh off Beeks. Nick Anderson relieved and retired Judge on the long fly for his second save.

"Crossed my fingers that it wasn't going out," Anderson said.

Pete Fairbanks (2-1) pitched the fourth to get the win.

Meadows' hit off Luis Avilan put Tampa Bay up 3-1 in the fourth inning. Avilan replaced spot starter Michael King (0-1), who allowed three runs on one hit and five walks in 3 2/3 innings.

Plate umpire Vic Carapazza warned the Yankees dugout during the top of the fifth in the nightcap about too much chirping and, after the half-inning ended, ejected hitting coach Marcus Thames. Boone ran out of the dugout to argue and was also thrown out by Carapazza.

"He misinterpreted what Marcus said," Boone said. "He should not have been thrown out of the game and that's that."

Cole was in control going into the fifth. With two outs and a runner on, Cole had a 1-2 count on Ji-Man Choi, who came back to hit an RBI double.

José Martínez followed with a two-run homer on the 107th pitch from a clearly tiring Cole. The right-hander stared in disbelief and went into a squat as Martínez's drive left the ballpark.

"Obviously pitch count got up there," Cole said. "I wasn't able to finish the outing the way we wanted to. They just ran the count."

Soon after Boone took a slow walk to mound to replace Cole with Chad Green (2-0), who got the win after allowing one run over 1 1/3 innings.

"He was really good," Boone said of Cole. "Credit to them, they made him work. A couple mistakes there at the end cost him."

Cole was bidding to tie Roger Clemens, Jake Arrieta and Rube Marquard for the third-longest streak ever. Hall of Famer Carl Hubbell leads the list with 24 in a row, followed by Roy Face with 22.

Cole struck out 10, walked one and gave up six hits. His only loss since May 2019 came in Game 1 of the World Series last October, pitching for Houston against Washington.

Ford also connected for the Yankees in Game 1, and Gio Urshela had three RBIs.

Rays starter Tyler Glasnow lasted just 2 2/3 innings, giving up four runs, five hits and three walks during a 71-pitch outing.

"It obviously didn't go as planned. I left too many good pitches over the plate and didn't get ahead of anybody," Glasnow said.

MILESTONE

Outfielder Brett Gardner played in his 1,510th game with the Yankees in Game 1 to move past Alex Rodriguez for sole possession of 17th place on the team's career list.

TRAINER'S ROOM

Yankees: C Kyle Higashioka was put on the 10-day injured list with a right oblique strain and will have an MRI Monday.

UP NEXT

Yankees LHP James Paxton (0-1) and Tampa Bay RHP Charlie Morton (1-1) are the scheduled starters in the series finale on Sunday.