No. 2-ranked Roger Federer loses to Kei Nishikori 6-4, 1-6, 6-2 in third round at Madrid Open

Roger Federer was ousted by Kei Nishikori of Japan with a 6-4, 1-6, 6-2 loss Thursday in the third round of the Madrid Open.

Following the loss by the second-ranked Swiss, Rafael Nadal is now the clear favorite for the title — or the next big name who should be wary of an upset.

Nadal didn't let his sore knee get in the way in a 6-2, 6-3 win over Mikhail Youzhny that put him in the quarterfinal, and third-seeded Andy Murray had to come from behind to edge past Giles Simon 2-6, 6-4, 7-6 (6).

"Clearly the favorite for this tournament is Nadal," Federer said.

Serena Williams and Maria Sharapova — the top two seeded women — also reached the quarters in straight sets.

Last year, Federer didn't let the slick "Smurf-colored" clay stop him from winning his third title in Madrid. But now with the old-fashioned red clay back at the Caja Magica, Federer only managed to look like the star he is for a spell.

Yet Federer wasn't the first highly-ranked player to exit. Top-ranked Serb Novak Djokovic was ousted Tuesday, a day before Victoria Azarenka followed in a temper tantrum.

After recovering from Nishikori's strong start, Federer looked as though he'd found his stride as he roared back in the second set, but Nishikori reasserted his ground game in the decider, breaking Federer for a 3-1 advantage before holding on for the surprising win.

Nishikori said beating Federer after losing their only previous meeting was one of the high points of his still burgeoning career.

"He was my idol and to beat him was one of the goals for my tennis career," the 16th-ranked Nishikori said. "Beating Roger is, yeah ... I need a couple of days to celebrate."

Federer came to Madrid after a seven-week layoff. He said the gusting winds hurt his game, but he gave all credit to Nishikori.

"He was the better player today for sure," Federer said. "I was lacking control from the baseline and that carried through from start to finish. Overall I'm disappointed with my play."

Federer said he will not change his plans and will now train for Rome and then the French Open.

This was Nishikori's fourth win over a top-five opponent. Nishikori will next play Pablo Andujar, who advanced when fellow Spaniard Daniel Gimeno-Traver retired.

Nadal's commanding win over Youzhny featured an array of winning shots.

Having already established control by stealing Youzhny's second service game, Nadal kept a point alive with a deft no-look backhand flick before nailing a winner down the line to hold his serve and delight his fans.

The fifth-ranked Spaniard then broke Youzhny again by dinking the ball over the net while on the run, giving it so much backspin it twisted away from the Russian.

Nadal, who is searching for his seventh straight final since returning from injury, improved to 28-2 this year.

Nadal said he was still bothered by his left knee, which has sidelined him this year with a nagging case of tendinitis.

"Sometimes I have pain," he said. "I try to avoid talking about it as much as possible. With respect to my rivals it's not the moment to analyze how I am."

Nadal's next opponent is David Ferrer, who outlasted Tommy Haas 7-5, 4-6, 6-4 to reach the quarters.

Murray looked stiff as he conceded the first set to Simon but the Scot improved from there, and after winning a long game to break back early in the second, slowly imposed his will. He did squander five match points before Simon netted his final approach shot in the tiebreaker to end it in just under three hours.

Murray will play Tomas Berdych, who defeated Kevin Anderson of South Africa 7-6 (5), 7-5, to make the final eight.

Also, Jo-Wilfried Tsonga beat Fernando Verdasco of Spain 4-6, 6-3, 6-2 to set up a match with Stanislas Wawrinka, who came back to see off Grigor Dimitrov 3-6, 6-4, 6-1.

On the women's side, the top-ranked Williams dispatched Maria Kirilenko 6-3, 6-1, after Sharapova put away Germany's Sabine Lisicki 6-2, 7-5.

Williams' dominant performance made Kirilenko wither after she dropped the first set with one of several unforced errors.

"I just felt really relaxed, like I was taking my time," said Williams, adding that she strived for precision over speed on serve.

Williams will take on local favorite Anabel Medina Garrigues, who advanced after Yaroslava Shvedova of Kazakhstan withdrew with a right arm injury.

Sharapova will face Kaia Kanepi of Estonia after she defeated Daniela Hantuchova of Slovakia 6-3, 6-4.

Ekaterina Makarova of Russia beat Marion Bartoli 6-3, 6-2 and will play Sara Errani following her 7-5, 6-3 win over Varvara Lepchenko. Angelique Kerber of Germany will meet former No. 1 Ana Ivanovic.