Thiem looked on course to become the first Austrian to win the title, following on from his recent U.S. Open triumph, but 24-year-old Medvedev turned the tide in superb fashion.
There was no celebration as he fired an unreturnable first serve on match point to end the contest and bring the curtain down on 12 memorable years for the tournament at London’s O2 Arena before it relocates to Turin next year.
Fittingly Medvedev became the first Russian to win the title since Nikolay Davydenko, who won London’s first edition in 2009.
It was no more than Medvedev deserved after a sensational week in which he became only the fourth player in ATP history to beat the world’s top three at the same tournament.
He outplayed world number one Novak Djokovic in the group phase in which he went 100%, then outlasted second-ranked Rafa Nadal in Saturday’s semi-final before stopping Thiem who finishes as runner-up for the second year in succession.
After an incredible run of form, including claiming this month’s Paris Masters, the Moscovite was perhaps due a dip and it happened in the first set as he threw away a 40-0 lead on serve at 2-2, gifting Thiem a break with a double-fault.
It proved enough for the Austrian to pocket the first set and he went for the quick kill in the second as Medvedev’s usually rock-solid serve and forehand wavered.
The Russian hung in though, saving break points at 2-2 and 3-3, and the second moved into a tiebreak.
Thiem led 2-0 but Medvedev then reeled off seven points in a row to ensure London’s farewell would go the distance.
Thiem, who had also beaten Nadal and Djokovic this week, had spent two more hours on court than Medvedev to reach the final and he began to fray in the third set.
Medvedev stalked him with his relentless power and accuracy and the Russian secured the break of serve he had threatened at 2-2 when he stroked away a volley.
Thiem dug in desperately but world number four Medvedev remained calm to become the fifth successive first-time winner of the title.