The Ghanaian rejoins former Blues boss Jose Mourinho, who brought him to England in 2005, at the Bernabeu.
The 29-year-old has made 247 appearances for Chelsea, scoring 25 goals and twice winning the club's goal of the season award.
He also helped the club to two Premier League titles, four FA Cups and last season's Champions League title.
Source: PA
Source: PA