Ian Rapoport of the NFL Network reports Fairley signed a one-year deal with a $5 million base that includes includes an additional $2.5 million in incentives.
Fairley spent the last four seasons with the Lions, who drafted him in the first round in 2011. On Wednesday, it was reported that Detroit told at least two agents that they were out of the running to sign Fairley.
The 27-year-old reportedly visited the Cincinnati Bengals on Wednesday and had interest from at least six teams.
Fairley was limited to eight games last season due to sprained ligaments in his knee, and he recorded 14 tackles and 1.0 sack. In 2013, he started 15 games and had 35 tackles, 6.0 sacks and two fumble recoveries.
Detroit recently also lost free-agent defensive tackle Ndamukong Suh to the Dolphins after he signed a six-year deal with Miami. On Tuesday, the Lions acquired defensive tackle Haloti Ngata in a trade with the Baltimore Ravens.
The Rams went 6-10 last season, finishing in fourth place in the NFC West.
- Molly Geary