Real Madrid icon David Beckham has paid tribute to departing Barcelona coach Pep Guardiola.

Guardiola announced on Friday he would be leaving Barcelona.

"Pep is not only a great coach, but also a gentleman," Beckham posted on his official Facebook page.

"I'm a fan of Real Madrid, but I loved the way his team played and he deserves everything he has achieved. I wish him well."