The Lions announced the move Tuesday.
The 27-year-old Stanford has spent the past three seasons with the Miami Dolphins. He played in five games for the Dolphins last season, making one start.
Stanford was drafted in the seventh round by Carolina in 2010. He played for the Panthers in 2011.
AP NFL website: www.pro32.ap.org and www.twitter.com/AP-NFL