The Astros led the AL wild-card race by a game heading into Sunday. They shared a few high fives in the dugout in the eighth inning after clinching it when the Los Angeles Angels lost to Texas.
Houston finished 86-76 to reach the postseason for the first time since playing the Chicago White Sox in the 2005 World Series. The Astros will play their first American League playoff game Tuesday night, against the New York Yankees at Yankee Stadium.
Photos from Astros vs Diamondbacks
Not bad for a team that had three 100-loss seasons before going 70-92 in 2014.
Arizona went 79-83 in its first season under general manager Dave Stewart and manager Chip Hale, a 15-game improvement from finishing with baseball's worst record in 2014.
Paul Goldschmidt hit a two-run homer off Chad Qualls (3-5) and A.J. Pollock had a solo shot among his three hits for Arizona. Daniel Hudson (4-3) got the final two outs of the seventh inning and Brad Ziegler recorded six outs for his 28th straight save, matching the team record set by J.J. Putz from 2011-12.
The Astros entered Sunday's game knowing they would play at least one more time this season.
Where, when and against whom were still up in the air.
PHOTOS: Your Astros fan pics Email pics to us at firstname.lastname@example.org
Houston had a chance to play Texas in a one-game playoff for the AL West title, a one-game playoff against the Angels to determine the second AL wild-card team or go straight to the wild-card game.
The Astros were hoping to take care of their end of things by sending out Lance McCullers, the 22-year-old who leads all AL rookies with 3.19 ERA.
Houston dug a hole right away, with Pollock hitting a long solo homer to center in the first inning. It was Pollock's 20th of the season, making him and Goldschmidt the first Arizona teammates to have 20 homers and 20 steals in the same season since Justin Upton and Chris Young in 2011.
But with Los Angeles leading Texas on the scoreboard, the Astros pulled even in the third inning on George Springer's run-scoring double.
McCullers escaped a bases-loaded jam in the third inning, but hurt himself in the inning by dropping a toss from first baseman Chris Carter for an error, then balking in a run to put Arizona up 2-1 as Texas took the lead over the Angels.
Houston tied it in the fifth on a fielder's choice by pinch-hitter Evan Gattis, but Arizona went back up on Jarrod Saltalamacchia's run-scoring double in the bottom half.
McCullers allowed three runs - two earned - on six hits and struck out six in five innings.
The Astros tied it at 3-all in the seventh inning on a wild pitch by Daniel Hudson, but Goldschmidt put the Diamondbacks up 5-3 with a towering two-run homer to left in the bottom half.
It didn't really matter to the Astros at that point; the Rangers were up 9-2 over the Angels in the eighth.
Astros: Houston will face the Yankees in the AL wild card Tuesday in New York.
(The Associated Press contributed to this report.) null