The Panama native tore ligaments in his left knee in May while catching fly balls in the outfield before a game and pitched in only nine games in 2012.
"I didn't want to go out like that," the 43-year-old Rivera said. "I didn't want that to be the last image."
No details were announced, but local media reports said Rivera had signed for $10 million (£6.25 million) plus incentives.
"It wasn't an easy decision because there's more than just baseball with me. I have to consider my family and the church, too," said Rivera.
"But I feel like we have a great group of guys and a team that can compete for a championship. I'm not just coming back to play. I'm coming back to win."
The right-hander, who has long baffled hitters with the deceptive, late movement on his cut fastball that bears in on left-handed batters, has 608 career saves and won five World Series titles with the Yankees dating back to the 1996 season.
A 12-time American League All-Star, Rivera's 42 postseason saves is the major league record.
His 18 seasons with the club tie him with Yogi Berra, Mickey Mantle and team mate Derek Jeter for the longest tenure at the storied franchise.
- Sports & Recreation