The Yankees brought it Matt Holliday during the offseason in hopes he would bat cleanup and provide a powerful right-handed bat to protect Gary Sanchez and Greg Bird.

With Sanchez expected to be out of action for a month with a muscle injury and Bird out as he battles a sore right ankle, the flu and a rotten first week of the season, there was Holliday, hitting third — in back of Jacoby Ellsbury and with strikeout machine Chris Carter behind him.

Pretty much wherever Joe Girardi has used him, Holliday has produced, and that continued in Monday’s 8-1 win over the Rays in the home opener in The Bronx.

By the time Holliday singled through the shift to right field in the bottom of the first, the DH had reached base seven straight times, beginning with a ninth-inning single Saturday and adding five walks in Sunday’s victory in Baltimore.

“I’m trying to contribute any way I can, whether it’s getting on base or driving in runs,” Holliday said. “I wasn’t worried about getting off to a good start here, but it’s always better than the alternative.”

With Sanchez sidelined, Holliday’s importance in the middle of the lineup figures to grow.

“There’s nothing we can do about it,” Holliday said of Sanchez’s injury. “We have to pick up, battle and fill in. You can’t try harder or do more. We have enough talent in here to score enough runs and win games.”

After striking out and grounding out, he did his real damage later in the game, as the Yankees put the Rays away with a five-run eighth.

With Brett Gardner on third after reaching on an error and stealing two bases, Alex Cobb got behind Holliday 2-0. The Rays brought the infield in and opted to pitch to Holliday rather than walk him with the struggling Carter and Starlin Castro next in the order.

After taking a curveball for a strike, Holliday pounded a 2-1 fastball to left-center. The run-scoring double made it 4-1. Holliday came around to score on Carter’s triple, and Girardi was able to avoid using Dellin Betances and Aroldis Chapman.

Holliday’s production since joining the Yankees isn’t unexpected. But his adjustment to being a full-time DH could have been an issue. He hadn’t started more than eight games as a DH prior to this season, since he spent his entire career in the National League.

But Holliday was insistent throughout spring training he would be able to figure out how to make the transition.

“I’d done it for whole series when we played in American League parks, and I was the DH for three straight games,” Holliday said. “I spend time in the cages and the clubhouse, staying as active as possible and keeping a sweat going, so you’re always ready to go. I’m just going to keep that going this season all the time.”

So far, the results are there. Through seven games, Holliday is 8-for-22 with three extra-base hits and eight walks.

On Monday, he was just fine with not drawing another walk.

“They threw me pitches to hit,” Holliday said. “That’s what I’m here to do.”