The 17-time grand slam champion, who won the last of his 77 titles last June, was beaten 6-1 4-6 6-3 by a typically gutsy Hewitt, who ended a more than three-year title drought.
World number six Federer, who had led their rivalry 18-8 before the final, looked to have turned the match his way after recovering from a slow start but Hewitt showed responded to claim the title in a little over two hours.
"To beat possibly the greatest player in the final means a lot," Hewitt said. "It's not an easy tournament to win.
"In the first set I was seeing the ball like a football. Didn't really matter where he served I was on it."
Federer had seven break points in the third set but failed to convert any of them as Hewitt ended a 15-match losing run against his fellow 32-year-old.
Despite the disappointment Federer remained hopeful for this month's Australian Open.
"I was able to sort of serve better overall, more consistent this week than I have in a long time - so that's very good," Federer, who had not dropped serve before the final, said.
"I definitely eeded a little bit more confidence to play well and hopefully win the tournament and so forth.
"I have a clear idea what I need to work on and I have a clear idea where my mind and body is at."
Federer can scarcely have opened a match in worse touch.
He hit 22 unforced errors in the first set, lost three service games and performed a complete air-shot off one attempted backhand service return.
"I was really struggling with all sorts of rhythm," Federer said. "I wouldn't say I was serving poorly, but it was just a tough set for me. I was put on the back foot very often."
Hewitt did not lose a point on his first serve in the opening set, making just three unforced errors as he took command with his trademark precision.
Federer improved markedly in the second set, coming back from 0-40 down to capture the Australian's serve in the ninth game and then served out to love to take the set.
Despite Hewitt's serve being far more consistently under threat in the third set he secured the only break in the fourth game when Federer hit a forehand wide.
Then, showing the resolve that made him a two-time major winner, the Australian held firm to secure his first ATP title in Australia since winning in Sydney in 2005.