Houston's deep lineup can create all sorts of problems for its opponents.

Like deciding whether to pitch to Jose Altuve or Carlos Correa.

Correa hit a game-ending RBI single in the 12th inning after Altuve was walked intentionally, sending the Houston Astros to a 4-3 win over the Kansas City Royals on Saturday night.

"He's been a very clutch hitter," Houston manager A.J. Hinch said. "I've seen that base hit to right-centre a handful of times during his short career. It does not surprise me that he put a good swing on a fastball away."

George Springer led off the 12th with a walk, and Alex Bregman followed with a bloop single into shallow right field that fell between three players. An error by Ryan Goins allowed Springer to advance to third.

"We had the shift on," Royals first baseman Hunter Dozier said of the bloop single. "Just perfect placement. We all tried, but we just couldn't get there."

After Altuve was awarded first, Correa singled into the gap in right-centre against Justin Grimm (1-3).

"You get in that situation you have to intentionally walk one," Grimm said. "Bases loaded and no outs, just battling with that guy. He put a good swing on a fastball in the outfield. It happened how it happened."

Correa said he was trying to drive the ball to get a sacrifice fly or something to the outfield. It was his sixth career game-ending hit and first since August 1, 2016, against Toronto.

"I don't know how many career walk-offs I have," Correa said. "Every single time they walk Altuve. They walk him because the best hitter in the game is hitting in front of me, but at the same time, it's not an easy task to walk him and get me out."

Collin McHugh (3-0) pitched a perfect inning for the win. Houston's bullpen combined for six shutout innings.

"Everybody up and down the staff, we know that our job is to get outs no matter what time of the game it is called upon us to do it," McHugh said.

Kansas City carried a 3-2 lead into the ninth, but Houston rallied against Brandon Maurer. After Yuli Gurriel and Josh Reddick singled with one out, Evan Gattis hit a tying sacrifice fly to left. Marwin Gonzalez then walked, but Brian McCann grounded out to end the inning.

The Royals wasted a solid start by Ian Kennedy in their 10th loss in 11 games. Kennedy allowed two runs and four hits in seven innings.

Kansas City jumped in front on Dozier's three-run homer in the fourth, but Correa hit a sacrifice fly and Gurriel homered to trim the Royals' lead to 3-2 in the bottom half of the inning.

"Hunter gave us a big lift with the three-run jack," Kansas City manager Ned Yost said. "We just couldn't really muster anything outside of that. If we could just find a way to tack on a run here or there it would be beneficial for us."

Houston right-hander Lance McCullers Jr. struck out nine in six innings. He permitted four hits and walked two.

ALTUVE MOVING UP THE CHARTS

Altuve tied Terry Puhl for seventh in Astros history with 1,357 hits with his double in the fourth. Altuve tied Bill Doran for ninth place in franchise history with 611 runs when he scored in the fourth.

HE SAID IT

"He's going to do that 99 times out of 100. He did exactly what I thought he would." — McHugh on Correa's game-ending hit.

TRAINER'S ROOM

Royals: 1B Lucas Duda (right foot) was recalled from his rehab assignment with Triple-A Omaha and started at designated hitter. He went 1 for 4 with a ninth-inning single. OF Paulo Orlando was optioned to Omaha to make room on the roster for Duda.

UP NEXT

Royals: RHP Jason Hammel (2-8) will make his 16th start of the season Sunday in the series finale. Hammel has a 2.85 ERA in nine appearances — eight starts — against the Astros.

Astros: RHP Gerrit Cole (8-1) will make his 16th start of the season looking for his seventh straight win. Cole walked a career-high five and allowed four runs for a second straight outing in earning a no-decision Monday against the Rays.