Madrid have accepted a €105 million (£92.7m) offer from the Serie A champions, while Ronaldo has agreed a contract worth €30m (£26.4m) per season with the Italian club.
The 33-year-old, who is Real Madrid's all-time leading goalscorer, was believed to have been pushing for an exit since the end of last season and the club from Turin broke the bank to land the Portuguese superstar this summer.
Ronaldo has spent nine seasons in Madrid, following his then-world record £80m transfer from Manchester United, and has gone on to become the club's record scorer with 451 goals. A major hint at today's news came right after the final whistle of this year's Champions League final when, having just won the trophy, Cristiano Ronaldo dropped the bombshell that he might well be leaving.
As reported earlier, Real Madrid forward Cristiano Ronaldo may move to Juventus.
He finished his letter by saying: "Thanks to everyone and, of course, as I said that first time in our stadium nine years ago: Hala Madrid!"
Real Madrid issued a statement on the move, thanking Ronaldo for his years of service and listing the many awards and accolades the team and player had achieved together.
"For every player, it would be great to play with Ronaldo, but I don't know if there has been contact with club and player", Can said. I am sorry it is like this and I ask all of you, especially our followers, to please understand me.
He said: "It was very nice to be at Madrid".
Ronaldo is on a postseason break in Greece following the end of a campaign that saw him help Madrid to a third straight Champions League title and then captain his country at the World Cup in Russian Federation.