NEW YORK — The Orioles made a statement this week.

The Yankees may still be the best team in baseball, but the Orioles are not far off. And they are definitely not going down without a fight.

Baltimore took two of three to win the series, putting up 17 runs against what, prior to Thursday’s onslaught, used to be the team with the lowest ERA. They rounded out the beating with a 17-5 win, and they have won five of seven against the Yankees this year.

The Orioles are only half a game behind the Yankees in the standings.

The Baltimore Banner thanks its sponsors. Become one.

“I’m really proud of our guys winning this series,” manager Brandon Hyde said. “The way we came out and swung the bat today, that was incredible. So many hard-hit balls early. Just really, really good at-bats. I don’t know what kind of statement we are making, but teams think we are a good team and our record shows it.”

The Orioles put on this performance with the bottom of their rotation on the mound, using pitchers who, if not for the onslaught of injuries, would not have been in these positions.

Albert Suárez was a low-risk minor league signing who, despite not having his best stuff Tuesday, kept the Orioles in the game, allowing three runs in 3 2/3 innings. Cade Povich, the rookie making his third career start, overcame early command issues to allow just one in 4 2/3 on Wednesday.

And Cole Irvin, who entered spring training expected to take on a bullpen role and be a depth piece, has been in the rotation all year. He too didn’t look as sharp as he has in other starts but, thanks to an onslaught of offense, he kept the Orioles in position to win.

Anthony Santander hit his 19th home run of the season and his 10th in June. (Jim McIsaac/Getty Images)

Thursday’s game, though, belonged to the offense, which put up a season-high run total. Yankees starter Luis Gil has been one of MLB’s best pitchers this season. He entered the day with a 2.03 ERA. He exited it with a 2.77 ERA.

The Baltimore Banner thanks its sponsors. Become one.

The Orioles scored seven runs off him. Gil lasted just 1 1/3 innings, the Yankees forced to turn to their bullpen early. They needed six relievers to get through the game, seven if counting position player Jose Trevino, who pitched the ninth.

“He’s got great stuff; we knew that,” designated hitter Ryan O’Hearn said of Gil. “He got us last time at home, but I think we just had a good game plan going in, trying to make sure we got him in the zone. .... We have good hitters who know how to control the zone. Obviously very motivated to take a rubber match against a good team. We’re chasing them down in this division, and I think guys came in locked in and ready to go today.”

Every Orioles batter except Ramón Urías got a hit. Gunnar Henderson and Adley Rutschman led the way with three hits each, while the veteran core provided the power with Anthony Santander, Cedric Mullins and Austin Hays hitting homers.

While Santander has heated up right alongside the temperature, hitting 10 home runs this month, Mullins and Hays have taken longer to get to this point. It was Mullins’ first homer since April 26 and just Hays’ third of the season, the other two also coming this month.

“That’s huge,” O’Hearn said. “We knew it was coming; those guys are too talented. We’ve seen what they’ve done over the years. More guys we can get hot in the lineup at one time, the better we can be.”

The Baltimore Banner thanks its sponsors. Become one.

It was the most runs the Orioles have scored since 2021, when Baltimore could only dream of being in the position it is now. The Orioles will head to Houston riding this high — with a chance to pass the Yankees in the standings.

“A lot of baseball left,” Hyde said. “We are going to face these guys in a couple weeks. A lot of things can happen, but we are happy we are where we are. We are in a good spot and want to just keep playing well.”