In their 47th career head-to-head, the Serbian moved to one win away from his fifth title at the tournament after triumphing 7-6 (6), 5-7, 7-6 (3) in over three hours to improve the record to 25-22.
"I mean, I won 20-plus matches in a row and had a most wonderful last five months of the year".
Cilic wrapped up the opener in the 10th game, ending Djokovic's 30-set win streak in the process.
Federer faced two break points in the opening game of the second set as Djokovic threatened to take control, but matters stayed on serve until a few minutes of uncharacteristic sloppiness from the Serb gave Federer a chance to level, which he took with a fizzing forehand victor.
The 22-year-old, ranked at number 18 in the world, simply refused to allow the new world number one to settle in the showpiece encounter.
The Swiss took the second set, however, when he broke Djokovic's serve late in the set, to force a third set.
Novak Djokovic was gracious in defeat and expressed his pride over "a most incredible last five months" after Karen Khachanov halted his 22-match winning streak to claim Paris Masters glory in a stunning upset on Sunday. "Maybe I'm not crying, but still I'm really happy", he told reporters later.
Karen Khachanov saved two match points against John Isner on his way to defeating the eighth-seeded American 6-4, 6-7 (9/11), 7-6 (10/8).
Driver likely intoxicated in crash that killed 4
In Wisconsin, the school, the community of Scouts and most of Chippewa were preparing to attend a memorial at 6 p.m. Woldhuis said the mother and daughter who died attended Chippewa Valley Bible Church, where he presides.
Djokovic is two wins shy of tying Rafael Nadal's record with 33 ATP Masters 1000 titles.
"It was a very intense match", Djokovic said.
"He is an inspiration to many players and he is a true champion of our sport", Khachanov said of Djokovic, adding that the victory in Paris was "like a dream come true".
He secured victory on his first match point when Djokovic chopped a backhand return wide. "And I told him to tell him to keep it down a little bit because he was going a little bit too much over the edge".
Nonetheless, the Muscovite deserved all the credit for the quality of his power game as he broke the world number five's serve six times in 70 minutes to set up a last-four meeting with either Jack Sock or Dominic Thiem, who were playing later.
Federer remains one short of 100 career titles.
Khachanov won the Kremlin Cup in Moscow last month for his third career title.
"As I said for the French Open, I will decide at the end of the year to see how it will have an impact on my physical training".