Marisnick, 28, a smooth-fielding center fielder, wasn't an everyday player for the Astros because of his inconsistency at the plate. He batted .233 with 10 homers and 34 RBIs for the Astros last season in 73 starts.
"Jake is an elite defender who is an incredibly smart base runner," Mets general manager Brodie Van Wagenen said in a statement. "Among our offseason plans was to improve defensively and he is one of the best in the game."
Marisnick, who has one year left on a contract that will pay him $3 million in 2020, is a career .227 batter, with 54 home runs and 178 RBIs in seven seasons with the Marlins and Astros.
In return, the Astros get lefty relief pitcher Blake Taylor and outfielder Kenedy Corona from the Mets.
Taylor, 24, was 2-3 with 10 saves, a 2.16 ERA and 74 strikeouts in 40 appearances as he rose through the Mets' system at Class-A Port St. Lucie, Double-A Binghamton and Triple-A Syracuse.
The 19-year-old Corona hit .301 with 23 extra-base hits and 19 stolen bases in his first professional season.