The 29-year-old center had 13 goals, nine assists and 144 penalty minutes in a career-high 76 games last season for Montreal's Hamilton affiliate in the American Hockey League.
The deal with the Rangers was announced Thursday.
Tarnasky also led Hamilton in penalty minutes and tied for fifth on the team in goals and power-play tallies (four).
In 245 career NHL games during five seasons with Tampa Bay, Nashville, and Florida, Tarnasky has 13 goals, 17 assists and 297 penalty minutes. His last NHL appearance was with Florida during the 2009-10 season.