Kevin Demoff, the team's chief operating officer, confirmed the signing Sunday night.
The deal is for four years and could be worth up to $36 million, a league source told ESPN's Adam Schefter. The St. Louis Post-Dispatch reported the deal was worth $36 million.
Long was placed on injured reserve by the Miami Dolphins in December because of a left triceps injury.
Before that injury, the 27-year-old left tackle had missed only two games in five NFL seasons. He was chosen a Pro Bowl starter each of the four years before 2012.
The 2008 No. 1 overall pick has become a less dominant blocker as his injuries accumulate. He was slowed by an ankle injury as a rookie and hurt his shoulder in 2010. In 2011, he battled back trouble, then missed the final game with a torn right biceps.
Long's decision reportedly came down to St. Louis and a return to Miami. He spent three days in St. Louis last week and took a physical before returning to Miami without a contract, as the Dolphins tried to re-sign him.
According to the league source, the Pittsburgh Steelers made a play for Long as well, although it occurred after Long's negotiations were too far along with St. Louis.
Rams general manager Les Snead would not get into specifics regarding negotiations or concerns over Long's injury history. In general, though, he said injury concerns were not a factor from the Rams' standpoint.
"What I'll say is, health is not a problem," Snead said.
Information from ESPN NFL Insider Adam Schefter, ESPN.com's Mike Sando and The Associated Press was used in this report.