Federer, 33, felt unable to take part in the showpiece clash at London's O2 Arena after suffering the back problem during Saturday's gruelling three-set semifinal victory over Swiss compatriot Stan Wawrinka.
"Unfortunately I'm not match fit to play match tonight," the Basel native said.
"Clearly I wish it wasn't this way," six-time Tour Finals champion Federer told the crowd during an on-court interview.
"You try all year to be ready for the ATP World Tour Finals and I didn't want to end this way," he said.
"I'm sorry I'm here in a tracksuit — I wish it weren't so," he said.
"I tried everything I could last night and today — painkillers, rest — until the very end, but I can't compete at this level with Novak.
"In a final like this and at my age, it would be too risky. I hope you understand."
The 17-time Grand Slam champion is due to lead Switzerland's challenge against France in the Davis Cup final, starting in Lille on Friday.
The prospect of missing out on a first title in the team event if he aggravated the back problem against Djokovic may have influenced his decision.
"I hurt my back late in the match yesterday against Stan," Federer said.
"I am very disappointed and I hope to be feeling better soon," he said.
"It's been an extremely difficult decision because I love playing in London and the ATP World Tour Finals have been an absolute highlight of my career.
"Unfortunately, my back problem does not allow me to play right now. I hope all tennis fans and those involved in the event will understand."
Sunday's withdrawal was only the third walkover of Federer's career.
Speculation of a withdrawal mounted when Federer, who took nearly three hours to defeat Wawrinka in a match that didn't finish until nearly 11.30pm local time, failed to show up for a scheduled practice session on Sunday afternoon.
The world number two then confirmed his decision to pull out following the Bryan brothers' victory in the doubles final.
With Federer sidelined, Djokovic was awarded the Tour Finals title for the third successive year — making him the first player to achieve that feat since Ivan Lendl in the 1980s.
It was hardly the way the world number one would have wanted to take the silverware however.
Fans were already streaming into the 17,500-capacity south-east London venue when the announcement of Federer's withdrawal came less than an hour before the scheduled start.
Djokovic agreed to play an exhibition match against Andy Murray in a bid to at least partially satisfy a disappointed crowd, who had paid high ticket prices (from £95 to £500) to watch a fascinating encounter between the world's top two.
There was also scheduled to be a legends doubles exhibition between Andy Murray and John McEnroe and Tim Henman and Pat Cash.
Chris Kermode, the ATP's executive chairman and president, revealed Federer spoke to him after tweaking his back in the deciding tie-break against Wawrinka.
Kermode then rang Murray on Sunday afternoon to ask if he would play the exhibition.
"It's amazing that he's come up and done it," Kermode said.