They were able to escape with a win despite all the traffic on the bases by making big pitches when it mattered most.
Yuli Gurriel had two hits and drove in two runs as the Astros built a lead with a big first inning and held on for the 5-4 victory.
The Astros jumped on Detroit starter Edwin Jackson (3-6) for four runs in the first inning to go on top 4-1. They led by 3 when Detroit's Ronny Rodriguez hit a solo homer in the sixth before Travis Demeritte added one in the seventh to cut the lead to 5-4.
Detroit had runners at first and third with two outs in the eighth, but Will Harris struck out Demeritte to preserve the lead. Roberto Osuna allowed one hit in a scoreless ninth for his 28th save as the Astros won their second straight after losing five in a row.
"We had to work pretty hard for that win and I think our pitching staff (was) able to get some key punch outs when we needed it," manager A.J. Hinch said. "We stranded a lot of their runners, we had a big first inning with some two-out hits and we won ... credit to a lot of different guys."
Houston starter Wade Miley (12-4) allowed a season-high 10 hits, but just one of them was for extra bases, and three runs in 5 2/3 innings to win his sixth straight decision. He struck out eight without a walk.
The Tigers were 1 for 8 with runners in scoring position and stranded 11 runners.
Detroit designated hitter Miguel Cabrera had two hits and drove in a run before he was ejected for arguing balls and strikes in the fifth inning. Manager Ron Gardenhire was also ejected in that inning after yelling at home plate umpire Alfonso Marquez about Cabrera's ejection.
Gardenhire didn't speak to reporters after the game, with bench coach Steve Liddle talking instead.
He said Gardenhire was simply taking up for Cabrera.
"That was something that really irritated Ron and you can talk to him about it (Tuesday)," Liddle said.
Jackson yielded seven hits and five runs -- four earned -- in six innings for his first loss with the Tigers this season after winning his first two starts.
The Tigers led 1-0 after an RBI single by Cabrera in the first inning.
Alvarez hit an RBI double to tie it in the first inning. There were two outs in the inning when Gurriel doubled to center field on a ball just out of reach of Victor Reyes that scored two more and put Houston on top 3-1.
Robinson Chirinos followed with a single and he reached second and Gurriel scored on an error by left fielder Brandon Dixon on the play.
Demeritte and Cabrera hit consecutive singles with one out in the third inning and Demeritte scored on a sacrifice fly by Dixon which cut the lead to 4-2.
Jackson got on track after his tough first inning and pitched three scoreless innings before the Astros added a run on a sacrifice fly by Chirinos with one out in the fifth. Cabrera and Gardenhire were ejected with Alvarez at the plate with no outs in that inning.
After Cabrera was tossed, Gardenhire stormed out of the dugout screaming at Marquez. Gardenhire got right in his face and went on a profanity-laced rant that continued well after he'd been ejected. He finally made his way off the field as boos rained down from the home crowd.
Cabrera denied that he was complaining about balls and strikes and said he was speaking in Spanish to Altuve, who was on deck when he was thrown out.
"If you see the pitch he threw me out, it was down," Cabrera said. "So, there's no reason for me arguing that pitch. So, I said `It's unbelievable' ... I said that to Altuve not the umpire. When Gardenhire went over there he said he warned me three times but Gardenhire said, `He didn't even talk to you."
There were two outs in the sixth inning when Rodriguez homered to center field to get the Tigers within 5-3. Demeritte sent Hector Rondon's third pitch of the seventh inning to center field for a home run to cut the lead to 5-4.
Astros: RHP Gerrit Cole did some work on the field before Monday's game and manager A.J. Hinch is hopeful that he'll make his start on Thursday after being scratched from his start on Tuesday with discomfort in his right hamstring.
Monday was the first game since the Astros extended protective netting further down the left-field and right-field lines at Minute Maid Park. The move comes after a 2-year-old girl suffered a skull fracture when she was struck by a foul ball during a May game in Houston.
Tigers: RHP Spencer Turnbull (3-11, 3.75 ERA) will start for Detroit on Tuesday night. Turnbull allowed six hits and three runs while striking out eight in five innings of a loss against the Mariners in his last start.
Astros: RHP Aaron Sanchez (5-14, 5.79) is scheduled to start for Houston on Tuesday. Sanchez yielded seven hits and six runs in 5 1/3 innings in his last start but did not factor in the decision in a 7-6 loss to Oakland.
More AP MLB: https://apnews.com/MLB and https://twitter.com/AP-Sports
Gonzales scheduled to start for Seattle against Minnesota
Minnesota Twins (26-39, fifth in the AL Central) vs. Seattle Mariners (32-35, fourth in the AL West)
Peterson expected to start as Mets host the Cubs
Chicago Cubs (38-27, first in the NL Central) vs. New York Mets (32-25, first in the NL East)
Rockies take 4-game losing streak into matchup with Padres
San Diego Padres (38-29, third in the NL West) vs. Colorado Rockies (25-41, fourth in the NL West)
Eovaldi scheduled to start for Boston against Toronto
Toronto Blue Jays (33-30, third in the AL East) vs. Boston Red Sox (39-27, second in the AL East)
Orioles take 4-game slide into matchup with Indians
Baltimore Orioles (22-42, fifth in the AL East) vs. Cleveland Indians (34-28, second in the AL Central)
Gutierrez scheduled to start for Cincinnati against Milwaukee
Cincinnati Reds (32-31, third in the NL Central) vs. Milwaukee Brewers (38-27, second in the NL Central)