The Greek could not convert the lone break point in the opening set and the set went to a tie-break.
But at 5-5 in the breaker, Tsitsipas produced one of best points of the match and finished it with a forehand volley winner. He converted the opportunity with an aggressive forehand and let out a roar of delight.
The second set remained tight but Medvedev fatally opted to let a forehand go when rushing the net at 4-4 and it landed well inside the baseline, giving the Greek a break point.
Medvedev then hit a backhand long to give Tsitsipas the first break of the match and he did not let his chance slip, serving out for victory.
The two players have a spiky relationship.
Tensions flared between them at the 2018 Miami Open and Tsitsipas recently labelled Medvedev’s way of winning as “boring” after defeat against the Russian in Shanghai.
“It was one of the toughest, most important victories of my career so far,” said the Greek world number six.
“I gave myself a big boost, I kept believing, kept fighting, believing in myself, and that last game was one of the toughest.”
“I had great support, there are Greek flags everywhere, it feels like I’m playing in Athens,” he added. “I had goosebumps.”
World number four Medvedev, 23, has emerged as the leader of the pack of young tyros bidding to unseat the old guard of Nadal, Novak Djokovic and Roger Federer.
Four of the eight competitors at the ATP Finals at the O2 Arena are under 24 for the first time in 10 years.
Nadal, takes on defending champion Alexander Zverev in the later match in Group Andre Agassi with major questions over his fitness since he withdrew injured from the Paris Masters at the semi-final stage.
The Spanish top seed is locked in a battle with Djokovic to finish as the year-end number one but was not serving flat out in practice last week due to an abdominal strain.
Regardless of Djokovic’s results this week, Nadal will clinch the year-end top spot for a fifth time if he reaches the final with a 4-0 record.
Nadal has qualified 15 straight times for the year-end championships but he has only made eight prior appearances due to injuries.
Djokovic launched his bid for a sixth ATP Finals title with a comfortable win against Matteo Berrettini on Sunday but Federer slipped to a straight-sets defeat against Dominic Thiem, putting his hopes of progress in serious jeopardy.