Gaby Sanchez drove in Chris Coghlan with a double in the bottom of the 11th, sending Miami to a 5-4 victory over Houston in the opener of a three-game series.
Brandon Lyon (0-1) failed to record an out, allowing Coghlan to reach with an infield single to third. Sanchez followed by lacing the game-winning hit to left.
It made a winner of Ryan Webb (1-0) who turned in a scoreless top of the 11th for the Marlins, who had dropped two in a row at Philadelphia.
J.D. Martinez finished with two hits, including a two-run homer, and two runs scored for the Astros, who have lost three in a row.
Jordan Schafer began the game with a walk, stole second and scored on a Jed Lowrie base hit, but Miami responded with two in the home first on a Giancarlo Stanton RBI double and run-scoring hit from Omar Infante.
Astros starter Lucas Harrell's wild pitch with the bases loaded in the third brought home the hosts' third run of the contest, then the Marlins went up 4-1 in the third as Houston first baseman Carlos Lee's throwing error on a Coghlan grounder plated Infante.
Houston began its comeback in the fourth as Martinez led off with a single, moved up on a walk to Brian Bogusevich and crossed the plate on a Jason Castro single.
In the eighth, Lowrie's leadoff single was followed by a two-run shot from Martinez.
Miami starter Ricky Nolasco worked five innings, allowing four hits and two runs with three walks and as many strikeouts...Harrell ended up charged with seven hits and four runs over four full frames...The Marlins took six of seven from the Astros last year.