"He's a difference maker in the middle of the order when he gets pitches to hit and hits them hard," manager AJ Hinch said. "It's nice to have him back obviously. He's still not moving around great ... but he made a huge impact today."
The Mariners led 1-0 after J.P. Crawford homered into the bullpen in right-center with one out in the first.
George Springer drew a leadoff walk in the bottom of the inning before a single by Jose Altuve and a walk by Alex Bregman loaded the bases. Alvarez then doubled on a line drive to right field to score two and put Houston up 2-1.
There was one out in the third when Bregman tripled to left field. Alvarez pushed the lead to 3-1 when he scored Bregman on a single to right field.
Cole (8-5), who allowed just four singles after the homer to Crawford, struck out 10 and walked one to win his fourth straight decision. Cole leads the American League with 151 strikeouts this season.
Cole was asked about throwing 100 mph in the seventh inning when his pitch count was already over 100.
"I just like to leave it out there," he said. "I just like to feel like I put in a good day's work. When you get that privilege to go back out and you get the leash to go over 100 pitches you respect that. You respect the guys that have been battling for you for the previous seven innings to keep the score where it is. So, you just want to leave it out there and make sure you did everything you could."
After consecutive one-run wins in the 10th inning, the Astros didn't need any late dramatics in this one. They padded the lead with a three-run eighth inning highlighted by a two-RBI single by Jake Marisnick.
Mariners starter Marco Gonzales (9-7) allowed six hits and three runs while walking three in five innings to snap a four-game winning streak in his first loss since June 2.
Domingo Santana had two hits for the Mariners, who lost their fourth straight overall and fell to 1-9 against the Astros this season.
"Our guys had good at-bats, very competitive games, you're one swing or one big hit away from getting over the hump and winning a couple of these games and we will," Seattle manager Scott Servais said. "The experiences our guys are gaining right now are very valuable."
Santana singled again with two outs in the sixth, but Cole retired the last four batters he faced with two strikeouts to end his day and keep the Mariners from cutting the deficit.
Mariners: 2B Dee Gordon was out of the lineup on Sunday after leaving Saturday night's game with a strained quadriceps.
Astros: 1B Yuli Gurriel sat out on Sunday to rest with a sore right ankle after he turned it on Saturday night. Hinch said he's fine, but that he thought he needed a day to recover after tweaking it running the bases in Saturday's win.
With his home run on Sunday, Crawford has reached safely in 30 of his 33 games and is hitting .309 in that span.
"J.P.'s playing really well," Servais said. "Doing everything defensively, the quality at-bats are really good. We need it to continue, he's in a good spot right now."
Mariners: Seattle is off on Monday before opening a three-game series with St. Louis on Tuesday where they'll start an opener who has yet to be announced.
Astros: Houston is also off on Monday before traveling to start a two-game series at Colorado on Tuesday. Hinch declined to say who will start for the Astros on Tuesday.
More AP MLB: https://apnews.com/MLB and https://twitter.com/AP-Sports
Sources: Pirates hire Ben Cherington as new GM
The Pirates have hired Ben Cherington as the team's new general manager, according to multiple reports and confirmed by ESPN.
AL Central offseason preview: Francisco Lindor's future, Twins' rotation in focus
The Indians have a big decision to make about their biggest star, Minnesota needs a lot of arms and the White Sox could be on the cusp of good things.
Way-too-early 2020 MLB awards predictions
Will Juan Soto rise to the top? Can anyone unseat Mike Trout? Here's the first look at next year's hardware hopefuls.
Trout on 3rd MVP: 'I always try to be the best player'
Mike Trout joins SVP after winning the American League MVP award and says it was special to be recognized as the league's best player for the third time.
Bellinger: Winning MVP 'means everything'
Cody Bellinger joins SportsCenter after being announced as the National League MVP and describes how special the award is to him and his family.
Angels' Mike Trout edges Astros' Alex Bregman for AL MVP
Angels center fielder Mike Trout became just the 11th player with at least three MVP awards when he was named the American League's MVP on Thursday. Trout edged Astros third baseman Alex Bregman for the award.