MADRID—Top-ranked Rafael Nadal is back in a clay court final at the Madrid Open, where Japan's Kei Nishikori denied an all-Spanish meeting by converting his 10th match point in a grueling victory over David Ferrer on Saturday.

Nadal, the defending champion, reached his first clay final since winning in Rio de Janeiro in February with a 6-4, 6-4 win against countryman Roberto Bautista Agut.

Ferrer saved nine match points before Nishikori ultimately overcame his late nerves for a 7-6 (5), 5-7, 6-3 victory that spanned two hours, 55 minutes and propelled him into his first Masters series final.

Earlier, Maria Sharapova held her nerve to reach her second consecutive women's final, where she will play Simona Halep of Romania.

After Nishikori won the first set, Ferrer delivered an ace to save his first match point in the 10th game, then broke Nishikori on the fifth try one game later. Ferrer took it to a third set after saving two break points.

Despite needing treatment on his right thigh before the start of the deciding set, Nishikori's powerful groundstrokes overwhelmed Ferrer for a key break in the sixth game. There was a dramatic ninth game that lasted nearly 20 minutes.

More than an hour after his first match point, Nishikori reached triple match point serving for the final at 5-3, but netted three shots in a row trying to finish. Ferrer earned break points, but Nishikori saved the first with an ace down the middle and the second with a service winner.

Nishikori smashed error after error with victory in his grasp as the local fans backed Ferrer, who ultimately hit long for the 12th-ranked Nishikori to earn his 14th straight win, including a perfect 10-0 on clay this season.

It was his second consecutive duel with Ferrer in a Masters tournament. Nishikori fought off four match points to edge Ferrer, 7-6 (7) 2-6 7-6 (9) in Miami in March.

Bautista Agut, playing in his first career Masters series semifinal, couldn't match the experience of Nadal, who continues to improve after coming to the Magic Box center having lost at consecutive clay tournaments for the first time in a decade.

Nadal took advantage of Bautista Agut's timid start to break right away for a lead he would never surrender.

Nadal's concentration dipped temporarily in the second set as Bautista Agut clawed to within 4-3 before Nadal overcame his 21 errors by pulling away to reach his 90th career final.

"Psychologically speaking about Monte Carlo and Barcelona, whenever I had nerves, I was not ready and I was a little bit down," said Nadal, bidding to be the first repeat winner from his sixth final appearance.

"I am mentally more stable and more confident things will go well. This is great news going into tomorrow's match and for the future."

Sharapova was cruising against Agnieszka Radwanska before allowing the third-seeded Pole to break back in the second set. But the eighth-ranked Russian recovered to secure a 6-1, 6-4 win after Halep rallied in the hot conditions to dispatch 2011 champion Petra Kvitova 6-7 (4), 6-3, 6-2.

Sharapova has lost just three times on clay since the 2011 French Open, with all of those losses coming against two-time defending champion Serena Williams. But Williams withdrew on Friday with a left thigh injury.

Kvitova looked on course for victory before unforced errors and the rising temperatures took their toll.

The Czech was 2-0 up in the second set and rolling against Halep, who was visibly frustrated after a late call went against her during the first-set tiebreaker.

But Kvitova hit 66 unforced errors and that inconsistency caught up with her as Halep recovered, with the now composed Romanian hitting 22 winners and breaking Kvitova four times over the last two sets.

"I just started to play more angles, more higher the ball, and just fighting for every point," Halep said.

Kvitova struggled in the final set, looking sapped of energy by the end of a match that lasted more than 2½ hours.

"Tomorrow I expect a very tough match. Maria is a champion and she knows how to manage the finals," said the fifth-ranked Halep, who reached her first Masters series final.

Sharapova hit 28 winners to four for Radwanska, who netted a forehand on match point to be broken for a seventh time.

"She's having a great year so it's going to be an extremely difficult match," Sharapova said.