HOUSTON — The Texas Rangers continue to find ways to beat the Houston Astros.

Jurickson Profar hit a tiebreaking RBI single in the ninth, and the Rangers handed the Astros another difficult loss by rallying for a 3-2 win on Tuesday night.

Rougned Odor helped set up Profar’s clutch swing when he reached on a wild pitch after striking out with one out. He swiped second and scored on Elvis Andrus’ two-out triple against Ken Giles (2-4).

“That’s a credit to our team,” Andrus said. “Odor battled that at-bat and even on a strikeout, gets to first base. Then, a huge jump to get to second. I think that’s what separates this team from past years. We don’t give up until the last out. It was another amazing win.”

Profar followed with a base hit into left field, helping AL West-leading Texas improve to 15-3 against Houston this year. Alex Claudio (4-1) pitched the eighth for the win, and Tanner Scheppers worked a perfect ninth for his first save.

“Again, Elvis with a huge hit,” Rangers manager Jeff Banister said. “He got a curveball up that he can drive. He got one and put a great swing on it. Profar similar, looking for a ball up that he could attack. He got good barrel on it to drive Elvis in.”

It was Giles’ fourth blown save of the season, but first since June 18 against Cincinnati.

“Things didn’t go our way, go my way,” Giles said. “It’s my responsibility to shut the guys down. I didn’t do my job today. I take full responsibility for that. I didn’t make the pitches when I needed to so I’m just going to take the good from the bad and just bounce back for the guys next time.”

Houston (75-70) has lost three in a row and six of seven. It is 4 1/2 games back of Toronto and Baltimore for the top spot in the wild-card standings.

“I’ve seen and been in some tough ones,” Houston manager A.J. Hinch said. “This one’s pretty hard. We had every chance to win the game and obviously strange things happen when we play these guys.”

Jose Altuve homered in the fourth and Jason Castro connected in the sixth, sending a drive to the upper deck in right field to give the Astros a 2-1 lead.

Adrian Beltre led off the second with his 30th homer for Texas (87-59). Beltre fell to a knee after swinging, but his towering shot traveled all the way to the Crawford Boxes in left.

Houston right-hander Brad Peacock allowed three hits in six innings. He retired his last 10 batters.

Texas right-hander A.J. Griffin also pitched well, striking out seven in a season-long seven innings. Griffin has allowed 26 homers this season and seven over his three September starts.

TRAINER’S ROOM

Astros: LHP Dallas Keuchel, who hasn’t pitched since Aug. 27 because of inflammation in his left shoulder, probably will not throw Wednesday, Hinch said. “We are going to go day to day and see if we can increase any type of activity, but his target date is a little gray area than anything else,” Hinch said.

WATCH YOUR STEP

On Evan Gattis’ towering popup in the fifth, Andrus came in from shortstop and walked up the back of the pitcher’s mound. As he made the catch, Andrus appeared to trip on the top of the mound and fell, but hung on to the ball.

Altuve also lost his footing during the game, but his fall did not have a good result. Altuve hit an infield single off third base in the sixth that was fielded by Andrus. Altuve made a wide turn around first and slipped in the dirt about 15 feet past first. Andrus double-pumped and then fired to first as Altuve had issues getting his footing back and was tagged out.

UP NEXT

Rangers: LHP Derek Holland (7-7) will start Wednesday instead of RHP Yu Darvish, Banister said following Tuesday’s game. Darvish will move behind LHP Cole Hamels in the rotation and start Saturday.

Astros: RP Joe Musgrove (2-4) will take the mound Wednesday night for the Astros looking to repeat the success he had in his last start Friday against the Cubs when he allowed two runs in six innings.