The Swiss, 38, beat the Hungarian 4-6 6-1 6-2 6-2 and will play American Tennys Sandgren in the last eight.
After losing the first set, Federer breezed through the second and third, winning seven successive games.
He twice broke Fucsovics in the fourth set before serving out the win on his third match point.
Federer battled for more than four hours to see off John Millman in the third round and he looked unsure of the wind conditions on Rod Laver Arena.
However, the 20-time Grand Slam champion found his footing and showed some fine touches at the net in the final two sets to reach the quarters.
"The morning after the [Millman] match and this morning, I lay in bed and after an hour I was wondering how to get up," Federer said.
"I'm sure I'm going to feel better every day that goes by.
"I had a good start to the second set and from then on it got a little bit easier."
Federer breezed through his first two matches but he was punished for a sluggish start by Millman and then again by Fucsovics on Sunday.
Fucsovics has been in superb form at the Australian Open - the only set he dropped prior to facing Federer was in his first-round win against 13th seed Denis Shapovalov - and he made the first break of the match.
The Hungarian capitalised as Federer's backhand let him down and he remained composed to serve out the first set in 37 minutes.
However, the Swiss stepped up in the next three sets, breaking Fucsovics early in each one as he grew stronger in his movements.
Federer was particularly strong at the net, winning 31 of 37 points from there, and his backhand, particularly down the line, became more fluent as the match possessed.
While his forehand could be wayward at times, particularly in the four-minute final game as he looked to close the set out, he was able to come through the match without any more significant problems.
"It was a tough start - I thought Marton played clean," Federer said.
"After Millman, the guy gave me a beatdown from the baseline, so maybe that took away my confidence a bit."
He will face Sandgren, who has come through three gruelling matches so far in Melbourne, in Tuesday's quarter-finals, while defending champion Novak Djokovic could await in the last four.