Defending champion and 24-time Grand Slam title winner Djokovic came from two sets to one down to defeat Lorenzo Musetti 7-5, 6-7 (6/8), 2-6, 6-3, 6-0 in a clash which only started just before 10:45 p.m. (20:45 GMT) on Saturday.
It was easily the latest finish to a French Open tie and came after organisers squeezed in extra matches onto the two main show courts, which both have retractable roofs, to counter the scheduling chaos caused by a seventh day of rain in Paris.
"I don't want to get into this debate," said Djokovic initially before adding: "I think certain things could have been handled differently.
"There is a certain beauty in winning the match at three in the morning if it was the last of the tournament, but this isn't the case."
Djokovic's four-hour 29-minute victory allowed the 37-year-old world number one to equal Roger Federer's record of 369 Grand Slam match wins.
"Physically, I really went to my limits to win this match. When you play rallies of more than 20 shots, at two in the morning... Who plays at two in the morning?" he added.
"We play few matches in our life at this time. The conditions were very heavy, it was very cold. You didn't have many free points behind your serve."
Djokovic must now recover to face Argentinian 23rd seed Francisco Cerundolo in the round of 16 on Monday after avoiding what would have been his earliest exit at the French Open in 15 years.
"I definitely think it's not healthy," said women's world number three and US Open champion Gauff.
'Not fair'
"It may be not fair for those who have to play late because it does ruin your schedule.
"I definitely think for the health and safety of the players it would be in the sport's best interest to try to avoid those matches starting after a certain time."
Gauff explained that a 3:00 a.m. finish didn't mean the end of a player's commitment for the day as a match is usually followed by physical recuperation and media duties.
"So that's probably not going to bed until 5:00 at the earliest, maybe 6:00, and even 7:00," said the American.
Women's world number one Iga Swiatek said night sessions need to start earlier for the sake of the public as well as players.
"I don't know if the fans are watching these matches if they have to go to work next day or something when the matches are finishing at 2:00 or 3:00 a.m.," said the defending champion.
"It's not up to us. We need to accept anything that is going to come to us."
In stark contrast to Djokovic's marathon efforts, Swiatek reached the quarter-finals on Sunday with a 6-0, 6-0 demolition of Anastasia Potapova in just 40 minutes on the same Court Philippe Chatrier.
Despite his reluctance to play late into the night, Djokovic's stamina and tenacity were widely praised.
"Djokovic is like LeBron James at 39, he fights until the end, he gives everything and he loves it, it's incredible to see," John McEnroe told NBC.
"I'm not kidding, this guy looked better physically than he did at the start of the match."
The Australian Open in Melbourne holds the Grand Slam record for the latest finish - in 2008, Lleyton Hewitt and Marcos Baghdatis played a match until 4:34 a.m.
At the US Open in New York, the record is 2:50 a.m. in 2022 when Carlos Alcaraz defeated Jannik Sinner.
Wimbledon operates a strict 11 p.m. curfew with the 2012 clash between Andy Murray and Baghdatis ending at a more gentle 11:02 p.m.
Alcaraz said he prefers to finish his matches by the evening, not the early hours.
"I don't like night sessions, we end so late, press conference, physio, ice bath," said the world number three and Wimbledon champion after making the quarter-finals on Sunday afternoon.
"For me it's much better to finish at 6:00. Everything is better if you finish early."