Mansfield have beaten off competition from several clubs to win the chase for former Stockport captain Matt Hamshaw.
The 24-year-old has signed a two-year deal at Field Mill after his release by the Hatters.
Hamshaw told Stags' website: "Mansfield is near my home in Rotherham and I can see it's a club going somewhere.
Midfielder Hamshaw spent 12 months at Stockport after a length spell at Sheffield Wednesday where he was a first-team player for five years.
Hamshaw had been linked with Bury and Rochdale since being released by the Hatters at the end of last season.