Casillas issued a statement on Tuesday to confirm he is calling time on a playing career that spanned more than 20 years.
The 39-year-old suffered a heart attack during Porto training in May last year and has not played since.
Casillas won five LaLiga titles and the Champions League on three occasions in a glittering Madrid career, while he was also a key part of Spain’s greatest period in international football.
He earned 167 senior caps for his country and captained them to back-to-back European Championships in 2008 and 2012 and the World Cup triumph in South Africa in 2010.
Although on the other side of the Clasico rivalry, Messi has no doubt Casillas deserves the highest praise for his career.
“Iker is retiring, but his status as a legend of the game was secured long ago – not just because he was one of LaLiga’s best players, but also because he won everything at international level,” Messi told AS.
In a message to the former goalkeeper, he added: “You’re a fantastic goalkeeper and were a really tough opponent, I have to say.
“Looking back, I think it was a really special rivalry that pushed us to reach new levels every time we came up against each other.”
Get breaking news alerts.
You have already subscribed