It has been 10 months since Nadal won a tournament, but he showed some of his old championship swagger by rallying past Nalbandian.
Nadal and Federer haven't played against each other since May in Madrid, but their paths to the final became easier when No 2 Novak Djokovic and No 3 Andy Murray lost their opening matches.
"It doesn't affect me a lot that Murray or Djokovic are out if I lose today," fourth-seeded Nadal said. As for who he might play next Sunday: "If I am in the final, I don't care."
A potential semifinal opponent is No. 6 Andy Roddick, who reached the final 16 by beating Sergiy Stakhovsky in 55 minutes, 6-2, 6-1.
Nadal will next face fellow Spaniard David Ferrer, who beat Ivo Karlovic 7-6 (5), 6-3. Olivier Rochus, who upset Djokovic in the second round, lost to No 27 Thomaz Bellucci 6-3, 6-4.
Advancing to the women's fourth round were Belgian pair and Grand Slam champions Justine Henin and Kim Clijsters. They could meet in the semifinals. Second-seeded Caroline Wozniacki and defending champion Victoria Azarenka also won.
In the early going against Nalbandian, it looked as though Nadal might have the coming week off. The Argentine, a former top-five player mounting a comeback from hip surgery, more than held his own in long baseline rallies and often found the open court with his backhand.
It was no fluke -- Nalbandian has beaten 16-time Grand Slam champion Federer eight times.
"Against a player with this talent, you are always a little bit scared," Nadal said.
As the opening set passed the one-hour mark, Nadal endured several wobbly moments, most notably when he double-faulted with a serve that missed by two meters.
"Amazing," Nadal said.
That made the score 5-all in the tiebreaker. Nadal regrouped to reach set point, then let it slip away and lost the final three points of the set.
But after dropping serve early in the match when he double-faulted on break point, Nadal held his final 11 service games. Nalbandian began pressing to finish rallies, losing two in a row when he tried drop shots, and his errors mounted.
"I felt he was a little bit more tired than me," Nadal said. "He started to have more mistakes, and was a little bit easier for me to play."
Nadal, hampered by knee trouble in recent months, has gone without a title in his past 12 tournaments. But with the clay-court season approaching, the four-time French Open champion is encouraged about the direction of his game.
He reached the semifinals at Indian Wells this month before losing to Ivan Ljubicic, and now he's trying to win his first title at Key Biscayne, where he was runner-up in 2005 and 2008.
"I'm very happy how I am doing in this American hardcourt season," Nadal said. "Every match right now I want to be really important for me, and every victory gives me confidence."
The unseeded Henin, mounting a comeback after a 20-month retirement, beat No 26 Dominika Cibulkova 6-4, 6-4. Clijsters, seeded 14th, swept the first nine games and needed only 51 minutes to beat No 17 Shahar Peer 6-0, 6-1.
Wozniacki, hampered by a viral illness and dizziness, rallied to beat No 32 Maria Kirilenko 1-6, 6-1, 6-4. Five games into the match, Wozniacki required treatment from a trainer, who checked her blood pressure before the match resumed.
"I just thought, 'OK, I don't have anything to lose,'" Wozniacki said. "I just tried to go out there and fight for every point. The third set I started to feel better."
The No 4-seeded Azarenka beat Lucie Safarova 6-4, 6-2.