NEW YORK _ Based on their five team errors and another empty night by Giancarlo Stanton, the Yankees' two-run deficit had seemed so much greater against the defending world champions.
But the Astros' shaky bullpen let them down on Tuesday night, enabling the Yankees to score a stunning 6-5 victory.
Brett Gardner's second homer of the game _ a game-tying, two-run shot to right off Chris Devenski _ suddenly brought Yankee Stadium back to life with one out in the ninth.
And by the 10th inning, Gleyber Torres' two errors hardly mattered.
Torres's two-out single off Brad Peacock scored fellow rookie Miguel Andujar with the winning run in a wild victory.
Andujar's two-out double preceded Torres's sharp single to right, getting the Yankees (34-17) even in this three-game series with Houston (35-21), which concludes Wednesday night.
Andujar had led off the ninth with a walk and Gardner soon followed with a towering shot that just cleared the right-center field wall _ causing Gardner to shoot his hand up triumphantly and releasing a roar from 45,458 fans, who were mainly frustrated to that point.
This time, the Yankees had managed to put a dent in Houston starter Charlie Morton (3 runs, 6 innings) though the Astros held the upper hand _ thanks in part to New York's season high five errors.
Before the game, Yanksee manager Aaron Boone said that "in some ways it feels like (the Astros) are maybe even a better team than they were last year.
"They're one of the teams that certainly stands in the way and creates a problem for us. It's also, having played now in the middle of our second series here in the last few weeks, it's also fun to be a part of these games where you're up against really great competition _ where you know you have to play your best if you're going to win each game. I think that makes it fun."
Representing the tying run, Stanton weakly grounded back to reliever Joe Smith to end the seventh inning.
He would break a 0-for-19 skid with an infield single in the ninth.
The reigning NL MVP and MLB home run champ couldn't help the cause of CC Sabathia, who lasted five innings and gave up five runs _ two of which were unearned.
Before the game, Boone acknowledged that Sabathia had received a lubricant injection to his arthritic right knee about 10 days ago. It was part of his routine maintenance on the knee and not indicative of any new issues.
After limiting the Yankees to just two hits over 7 2/3 innings in his win at Houston on April 30, the right-handed Morton matched that hit total against the first three hitters on Tuesday night.
Gardner homered on the second pitch and Greg Bird, inserted in the No. 3 spot, double to left.
Batting cleanup, Stanton tapped a weak grounder to second _ and stumbled twice as he attempted to run out of the box, adding to the struggling visual.
Consecutive two-out hits by rookies Andujar (double) and Torres (RBI single) restored a 2-1 Yankees lead, but Sabathia (2-2) gave up a two-run double to Marwin Gonzalez in the fourth and yielded two unearned runs in the fifth.
After third baseman Andujar's inning-opening throwing error in the fifth, Sabathia compounded it by losing a high-bouncing comebacker by Jose Altuve, then throwing the ball into right field _ setting up RBI by Yuri Gurriel (single) and Evan Gattis (sac fly) for a 5-2 Houston lead.
Settling in after the second, Morton lasted six innings, striking out 10 Yankees and giving up a tremendous solo homer to right by Aaron Judge in the fifth.
Just named the AL's Player of the Week for his five-homer week, Torres committed two throwing errors but none led to a run.
Stanton's slide was already a pregame topic for Boone.
"I just don't think he's got into that long stretch where he's that MVP that everyone wants to see," Booe said. "To me, that's about timing and rhythm (but) as many ups and downs as he's had so far, he's been really productive for us.
"I just don't think from a timing standpoint that he's really got it completely locked in, like I know he will at some point ... and we'll see that massive production happen on a more consistent basis."
But it could be time to examine whether Stanton's overly closed batting stance is deterring him from reaching the outside pitch _ causing his swings and misses and weak contact during this stretch.
"I certainly think it's a little unorthodox," Boone said of the stance. But after he closed off his stance last season with Miami, "his season really took off in an amazing way.
"He's a smart guy and a diligent worker," Boone said, acknowledging Stanton is always tinkering with hitting mechanics. However, "I think some level of being (in a) closed (stance) is something we all believe really works for him."