Elina Svitolina saw off debutante Viktoria Kuzmova of Slovakia 6-3, 6-4 to reach the third round.
But Zverev held his nerve to force a tiebreak, which he won comfortably and eventually prevailed in the final set to book his first trip to the last 16 of the tournament.
Djokovic's fourth-round opponent is Fernando Verdasco.
The gritty victory came with the usual temper flare-ups from Zverev.
He then broke his opponent and served out the set and match, winning it 7-5 to win his second five-set match in a row.
Still seeking a maiden grand slam title, Halep has lost two heartbreaking finals at the French Open, too, to Maria Sharapova in 2014 and Jelena Ostapenko past year.
Rafael Nadal can pull even with a 12th French Open quarterfinal by winning on Monday. His Grand Slam record was 0-4 before last week.
As for what sort of internal strife was happening in Zverev's head Friday?
"I have known of him for many years, " Djokovic said after his victory over Verdasco. If it takes me five sets, that's also great.
"I'm a normal person, even if I am No. 1 in the world", said Halep, popular in part due to her honesty.
In addition to the potential upsets, other top players were challenged in grueling matches, the most significant being women's #1 Simona Halep. "What can I say?" Khachanov has now won nine of the 10 sets played in this tournament and has a chance for this to be his breakthrough grand slam appearance at just 22 years old.
Jonathan's opening question was met with a bemused look from the world number three, who is fluent in English, before he replied 'where you from, buddy?' "It's not my favorite still but being in the round of 16 for a second time definitely makes it a little bit better". The set rolled on into a tie break that Zverev won by 7 points to 3.
But despite all the drop shots, the pummelled backhands and the animated pleas to the crowd for support, it proved not to be enough. Americans have not fared well in recent years here, but Querrey was one of the top hopes and showed promise today, but was unable to get the job done. "He was playing very smart in that moment".
She trailed Destanee Aiava 5-2 within the first set of her first match in Melbourne and saved three match factors within the third spherical towards Lauren Davis.
Dzumhur was so in the zone he failed to notice a ball boy advancing to collect a ball as the Bosnian went to grasp it, leaving the youngster floored and looking out for the count with Zverev on the ropes. But he then picked himself up with Dzumhur's help.
While Zverev still has time to make his mark at the highest level, Thiem wants to do better right now as he is almost 25 and feels that two French Open semi-finals in 2016 and 2017 might not be enough to quench his thirst. That didn't used to be the case, when Zverev was 12 and coached by Dad. That's all that matters.