Real agree to sign Carvalho
"Real Madrid and Chelsea have reached an agreement for the transfer of Ricardo Carvalho," Real said on their website.
"The player will be contracted to Real Madrid for the next two seasons."
GEAR: Get the new Chelsea kits
Chelsea said in a statement on their website the deal was subject to a medical and Carvalho agreeing personal terms.
The 32-year-old will rejoin his former boss and compatriot Jose Mourinho, who replaced Manuel Pellegrini as Real coach at the end of last season after leading Inter Milan to a treble of Champions League and Italian league and cup.
Mourinho took Carvalho with him to Chelsea from Porto following their 2004 Champions League triumph and he has been a near-permanent fixture in the centre of Chelsea's defence over the past six seasons.
During that time, he helped the London club win three English Premier League titles, three FA Cups and two League Cups and was part of the Portugal squad at the World Cup in South Africa last month.
He also joins up with international team mates Pepe and Cristiano Ronaldo at Real.
The Spanish club did not disclose financial details of the deal. Local media reported the fee was 8 million euros and said Carvalho had also agreed an option for a third season.
He is Real's fifth addition to the squad since the end of the last campaign following the purchase of winger Angel Di Maria and midfielders Pedro Leon, Sergio Canales and Sami Khedira.