NEW YORK – JC Escarra added walk-off RBI to his growing list of belated big-league firsts.

Pinch-hitting in Wednesday night’s 10th inning, the 30-year-old rookie’s long fly ball scored automatic runner Jasson Dominguez from third base, lifting the Yankees to a 4-3 win against San Diego.

“A lot was going through my mind,” said Escarra, as he batted for Oswald Peraza after Oswaldo Cabrera sacrificed Dominguez to third base.

“My heart was pounding through my chest,” said Escarra, who reminded himself to take “deep breaths” and react to Jeremiah Estrada’s pitches “instead of overreact.”

This was Escarra’s 29th at-bat in his 12th MLB game, having already checked off first MLB hit and home run after struggling through years in the minors and independent baseball, at one point driving for Uber to support his family.

“I’ve played a lot of baseball, most every league out there,” said Escarra, continuing to live out a dream daily with the first-place Yankees.

Escarra’s long sacrifice fly also gave the Yanks a series win against the tough Padres at Yankee Stadium, and the winning pitcher was the embattled Devin Williams in relief.

Starting the 10th inning in a 3-3 game, Williams loaded the bases (around the automatic runner at second) with two out when he got Xander Bogaerts to swing over a 3-2 changeup.

That strikeout sent Williams into a whirling frenzy as he hopped off the mound, with the fans at Yankee Stadium now cheering his exit back to the dugout.

Williams’ previous appearance came in Monday night’s 4-3 loss to the Padres, when he was charged with three earned runs.

Through seven innings, this was a taught pitching duel between San Diego’s Dylan Cease – who carried a no-hitter into the seventh – and lefty Max Fried.

The Yankees have won all eight of Fried’s starts, and Jackson Merrill’s solo homer in the fourth was the only damage against Fried on Wednesday.

Cease’s no-hitter ended with Cody Bellinger’s one-out homer in the seventh, on an 0-2 fastball, tying the game 1-1.

San Diego took a 3-1 lead in the eighth against the Yanks’ bullpen, but Trent Grisham’s pinch-hit, two-run homer in the eighth off Jason Adam tied it up.

Yankees slugger Aaron Judge (0-for-4, 3 strikeouts) saw his 32-game on-base streak end Wednesday, tied for the longest of his career.