The Italian said he was "sad and disappointed" to drop out, adding that he had started feeling unwell on Monday after a practice week in Monaco.
The 37-year-old, a two-time Olympic champion, is planning to play in the singles and doubles at his fifth Games.
The 38-year-old Spanish left-hander has a protected ranking of ninth to put himself into the field for the Flushing Meadows fortnight, which begins on August 26.
"I don't have any limitations in my mind. I still want to keep going and play as long as I feel like I can play on this high level."
"So let's see if at the end of my career it's going to be 25, 30, 15, four (Slams). I don't know. All I want to say is I want to keep enjoying and let's see what the future brings to me."
"To all the fans that have had respect and stayed here tonight, I thank you from the bottom of my heart and I appreciate it," said an angry Djokovic.
"Of course, I didn't want to take his last match away from him. But at the end of the day I think a lot of the players in a similar situation would have done the same thing, prioritising their body."
The Spanish world number three came through 6-3, 6-4, 1-6, 7-5 against his 16th-ranked opponent to book a spot in the last-eight of a major for the ninth time in just 14 appearances.
On a cold and wet day at the All England Club, only three of the women's top 10 were left in the draw, while Andy Murray's Wimbledon career ended with a whimper when Emma Raducanu pulled the plug on their mixed doubles plans.
The Italian said he was "sad and disappointed" to drop out, adding that he had started feeling unwell on Monday after a practice week in Monaco.
The 37-year-old, a two-time Olympic champion, is planning to play in the singles and doubles at his fifth Games.
The 38-year-old Spanish left-hander has a protected ranking of ninth to put himself into the field for the Flushing Meadows fortnight, which begins on August 26.
"I don't have any limitations in my mind. I still want to keep going and play as long as I feel like I can play on this high level."
"So let's see if at the end of my career it's going to be 25, 30, 15, four (Slams). I don't know. All I want to say is I want to keep enjoying and let's see what the future brings to me."
"To all the fans that have had respect and stayed here tonight, I thank you from the bottom of my heart and I appreciate it," said an angry Djokovic.
"Of course, I didn't want to take his last match away from him. But at the end of the day I think a lot of the players in a similar situation would have done the same thing, prioritising their body."
The Spanish world number three came through 6-3, 6-4, 1-6, 7-5 against his 16th-ranked opponent to book a spot in the last-eight of a major for the ninth time in just 14 appearances.
On a cold and wet day at the All England Club, only three of the women's top 10 were left in the draw, while Andy Murray's Wimbledon career ended with a whimper when Emma Raducanu pulled the plug on their mixed doubles plans.
She left Manhattan with the world at her feet, but the problems that have dogged her since provide a cautionary tale about the pitfalls of sudden celebrity.