On 1 July 2017, Hanzal as a first time free agent, signed a three-year, $14.25 million contract with the Dallas Stars. In his first season with the Stars in 2017–18, Hanzal missed the majority of training camp with the foot injury. He was then hampered by multiple injuries limiting his effectiveness in recording just 5 goals and 10 points in just 38 games. Approaching the final push for the post-season, on 9 March 2018, it was announced that Hanzal was ruled out for the remainder of the season to undergo a spinal fusion surgery to correct a persistent back injury with a recovery of six to seven months.