MADRID - Manuel Pellegrini has been named the new coach of Real Madrid, the Primera Liga club said on their website on Monday. Chilean Pellegrini will leave Villarreal to take over at the Bernabeu and will become the cornerstone of a new sporting project being put together by Florentino Perez, who was sworn in for a second spell as president earlier in the day. Spanish media reported that Real would pay Villarreal four million euros in compensation. Pellegrini joined Villarreal from River Plate in 2004 and has won praise for bringing through young talent, playing an attractive brand of possession football and making modest Villarreal a fixture in European competitions. He led them to runners-up spot behind Real Madrid in the Primera Liga in 2008 and steered them to the Champions League semi-finals in 2006 and the quarter-finals this year, where they lost to Arsenal. The 55-year-old replaces Juande Ramos, who was appointed until the end of the season after Bernd Schuster was sacked in December. LEAGUE CLASH Ramos led the team back from a 12-point deficit on leaders Barcelona to within four points before the league clash between the sides at the Bernabeu last month with a run of 17 wins from 18 matches. But Barca's crushing 6-2 victory broke Real's morale and Ramos was unable to prevent them falling away to lose their last five matches. Perez has spoken of the need to land up to six new signings and Cristiano Ronaldo, Kaka and Franck Ribery have been linked with possible moves. The pressure will be on Pellegrini to quickly rebuild the nine-times European champions, making them into a team capable of challenging treble-winners Barcelona. He will need to take the side beyond the first knockout round of the Champions League for the first time in six years, while entertaining a hugely-demanding and impatient fan base and management. Since coach Vicente del Bosque was sacked by Perez in 2003 after winning two Champions Leagues and two league titles in three and a half years, the club have gone through eight coaches. Carlos Queiroz, Jose Antonio Camacho, Mariana Garcia Remon, Vanderlei Luxemburgo, Juan Ramon Lopez Caro, Fabio Capello, Schuster and Ramos. Florentino Perez will present Pellegrini to the media on Tuesday.