Sonny Gray has spent the bulk of his 13-year major league career in smaller markets: Oakland, Cincinnati, Minnesota, St. Louis.

“I’ve always said I wanted to go to a market that is super-competitive, a big market that wants to win,” the veteran right-hander explained Tuesday in his first Red Sox media availability, following last week’s trade from the Cardinals.

“I always wanted another opportunity to prove to myself, and just go and be myself,” Gray continued. “Boston is a situation for me that works for me. I’ve been there, and gone there, and been around the city and the people, and talking to other people, that is a situation that I feel comfortable in. And that’s important to me.”

Sonny Gray on approving Red Sox trade: ‘More of a Boston guy than anything’

The veteran right-hander’s first time in one of baseball’s biggest and most formidable markets did not go as he or the team hoped. Gray pitched to a 3.72 ERA over 11 games when the New York Yankees acquired him midway through the ‘17 season, but posted a 4.90 ERA over 30 games for them the following year; according to Stathead, his 6.98 ERA at Yankee Stadium in ‘18 is the eighth-worst single-season mark in their franchise history (minimum 15 home games). He lost his rotation spot at the start of August ‘18, and the Yankees shipped him to Cincinnati the following January. His time in New York culminated in a 4.51 ERA, a far cry from his combined 3.47 mark with the other four teams.

Gray knows he will be asked about his time in New York “a decent amount” now that he is on the other side of baseball’s storied rivalry.

By choice this time. The no-trade clause in Gray’s contract, which runs through the ‘26 season with a club option for an additional year, gave him the power to veto or approve Boston or any other landing spot.

Going to New York had been out of his hands.

“It just wasn’t a good situation for me, it wasn’t a great set-up for me and my family,” Gray explained of his one and a half seasons with the Yankees. “I never wanted to go there in the first place.”

“I never wanted to go there,” he reiterated. “It just didn’t really work for kind of, who I am.”

Gray is far from the first player to have a suboptimal experience with the Yankees, and he joins a Red Sox team with some like-minded individuals. Closer Aroldis Chapman told the “Swing Completo” podcast he would “retire right on the spot… never again” if told he was being traded to the Yankees, with whom he pitched seven of his 16 big-league seasons. In June, rookie righty Hunter Dobbins introduced himself to the rivalry in a big way, telling the Herald he would rather retire than ever be a Yankee.

Other ex-Yankees on the Boston roster include catcher Carlos Narvaez and relievers Garrett Whitlock and Greg Weissert. Richard Fitts, acquired with Weissert in the rival clubs’ Alex Verdugo trade two Decembers ago, was one of two pitchers sent to St. Louis in exchange for Gray.

And of course, there are plenty of teammates who grew up rooting against the Yankees, or simply enjoy the heightened experience of beating the team they know Red Sox fans hate most. Like rookie sensation Roman Anthony, who was so excited to homer in his first career game in the Bronx – and silence the Bleacher Creatures who had heckled him from start to finish in the three-hour and 25-minute Red Sox win – that he flipped his bat for possibly the first time in his entire life.

Fuel-to-the-fire soundbites aside, Gray is grateful for his experience in New York.

“I do appreciate my time there,” he said. “I do feel like the last seven years of my career and my life and everything has been better. I’ve been a better baseball player, husband, everything, from having that experience and going through that. So I do appreciate that aspect of it, right? And I just feel like I learned so much after going through that.”

As soon as Gray left New York, he understood why it had not been the place for him.

“When I immediately left, I was just like, you know what? I never – I just wasn’t myself,” he recalled, “and I don’t know what led to that or anything, but it just wasn’t – it just didn’t feel like I was allowed to just, ‘Hey just go out there and be Sonny. Like, go out there and just be yourself.’”

Thus, another erstwhile Yankee is now a Red Sox. And he couldn’t be more excited.

“I will say,” Gray said, “what did factor into my decision to come to Boston is, it feels good to me to go to a place now where, you know what, it’s easy to hate the Yankees, right?”