Starlin Castro has started off the second half in the same fashion as he started the first, and this has been a welcome development for the Yankees’ offense.

Castro went 2-for-4 with a home run, a double and four RBIs in Tuesday night’s 7-1 victory over Baltimore, continuing his hot stretch. Since the All-Star break, he is 6-for-17, bearing more resemblance to the player who surged in his first month in pinstripes than the one who struggled much of May and June.

“I feel the same I felt at the start of the season right now,” Castro said. “I feel pretty good at the plate. The last couple of days, I’ve been working on something with Carlos and just put it in the game.”

In addition to the mechanical tweaks he has made with Beltran — Castro said Beltran noticed “something in my hands” in the batting cage — he said the time off during the All-Star break has been beneficial.

“I think those days off sometimes help as players,” he said. “You take a little breath and just come in ready.”

Castro led the Yankees with a .305 average in April, that went along with a .345 on-base percentage and .488 slugging but his performance dipped afterward.

advertisement | advertise on newsday

In 265 plate appearances from May 1 until the break, Castro hit .240/.277/.364, posting an uncharacteristically high strikeout rate. He went down on strikes in 19.2 percent of his PAs, and though it’s below the big-league average this season, it marked a 3.5-percent increase from his career rate.

Since the break, Castro has fanned once, and has driven in five runs, two of them in the second inning Tuesday night, when he blasted a two-run shot to leftfield. It was his 11th home run of the year, matching his total from last season with the Cubs.

In the sixth, his two-run double to right gave the Yankees a 5-1 lead. “We needed a little more runs to give a day off to the guys in the pen,” Castro said, in reference to relievers Dellin Betances, Andrew Miller and Aroldis Chapman.

“He’s swung the bat really well,” Joe Girardi said. “You look at the last three weeks and he’s been hot again for us. He’s a guy that has the ability to hit the ball out of the ballpark and drive in runs and that’s what he did tonight.”