A league source told ESPN NFL Insider Adam Schefter that Mathis' deal is worth $25.5 million with $7 million guaranteed.
The team said it reached agreement with Mathis on Saturday. Mathis, an unrestricted free agent, visited Baltimore on Friday.
Mathis is coming off his best season in his first year with the Eagles. He earned a starting job in training camp and moved into the lineup at left guard just days before the team's first game.
Information from The Associated Press contributed to this report.