Federer, who has slipped to seventh in the world rankings and faces a battle to qualify for next month's World Tour Finals in London, won 6-4, 6-3 against Italian Andreas Seppi after a testing start.
The Swiss great lost his serve early but broke back immediately against the world number 22, repeating the feat to take the opening set. A single break in the second was enough to seal the match.
Federer, who had a mixed bag of 19 winners and 29 unforced errors, said going a set up and then a break up in the second set was key for him and he started to feel comfortable.
"Even though it remained tough, Seppi did a good job of hanging around. That's the kind of match you want in this particular situation I'm in right now."
Earlier, German world number 23 Philipp Kohlschreiber rattled a feverish Juan Martin del Potro, striking 50 winners and 22 aces in a brave display of attacking tennis that had the Argentine searching for answers before he dug deep to win 3-6, 6-3, 7-6 (7/4). Third seed David Ferrer beat Lukas Rosol 6-3, 6-4, fourth seed Tomas Berdych beat Feliciano Lopez 7-6 (7/5), 6-2 and seventh seed Jo-Wilfried Tsonga eased past Pablo Andujar 6-3, 6-2.
There were also wins for seeds Tommy Haas, Stanislas Wawrinka and Kei Nishikori. But America's top player John Isner lost in straight sets to Argentina's Carlos Berlocq.
Britain's Andy Murray has withdrawn from the tournament as he recovers from back surgery. AAP