The Swiss great opened Group Boris Becker with a 6-4 7-6 (7-4) over American Sock in London on Sunday.
Federer, whose win was his 50th of the season, said he was pleased with his form, having last played competitively in his Swiss Indoors Basel final win over Juan Martin del Potro in late October.
"I'm happy that I was able to come out today and had actually good energy," he said, via the ATP World Tour.
"This is the best I've felt since the Del Potro final. I'm very happy to see that I didn't have to pay the price for taking it easy and resting and recovering.