The Rangers were shut out for the second straight day. Their lead for the second AL wild-card spot was cut to one game over idle Minnesota.
Texas missed a chance to gain on AL West-leading Houston and fell 2 1/2 games behind the idle Astros.
Cruz missed the previous six games because of a strained right quadriceps. He matched his career high for homers set last season with Baltimore, connecting for a two-run shot in a three-run seventh.
Hernandez (17-8) struck out eight and walked four. He tied Houston's Dallas Keuchel for the most victories in the AL.
Derek Holland (3-2) worked seven innings, allowing all five runs and nine hits.
The Rangers were blanked in back-to-back games for the first time since July 2013 at Cleveland. They have been shut out four times on their 10-game road trip.
Cruz became the fourth different Mariners player to hit at least 40 home runs in a season. Ken Griffey Jr. did it six times and Alex Rodriguez and Jay Buhner had three each. Rodriguez was the last to do it with 41 in 2000.
It was Cruz's 14th home run this year at Safeco Field, the most in a season at the ballpark since Jose Lopez in 2008.
Mark Trumbo's two-run homer in the first extended his hitting streak to a career-high 12 games. He's batting .375 with five home runs and 11 RBI during the string.
Rangers: Slugger Josh Hamilton will have arthroscopic surgery on his ailing left knee Friday. The team is hopeful he can return before the end of the season.
Mariners: LHP James Paxton, on the DL since May 29 with a strained left middle finger, threw a bullpen session Thursday morning. If he feels OK Friday, he will start Sunday, his first since May 28. ... OF Franklin Gutierrez (strained right groin) missed his sixth straight game.
Rangers: RHP Colby Lewis (14-8, 4.68 ERA) will make his fourth attempt at a career-best 15th victory, at home against Oakland. He has struggled his past three starts, going 0-3 with a 8.62 ERA. He is 9-4 with a 3.08 ERA in 25 career starts against the A's, his most wins against any opponent.
Mariners: RHP Hisashi Iwakuma (7-3, 4.03 ERA) is 5-1 with a 2.98 ERA over his last seven starts, including a no-hitter Aug. 12 against Baltimore. He has never faced Colorado.