In his first tournament since returning to the top spot of the ATP Rankings, the Swiss overcame a spirited effort from Argentina's Federico Delbonis to advance to the third round at the BNP Paribas Open on Sunday.
South Korea's Hyeon Chung, who surpassed all expectations to reach the Australian Open semi-finals earlier this year, also advanced, taking almost three hours to overcome Dusan Lajovic 6-7 (11/9) 6-3 6-3. The Melbourne event was Djokovic's first since Wimbledon last summer, as he was sidelined due to the elbow ailment that ultimately led to the operation.
Djokovic said he felt like it was his "first match" on tour and was unable to explain his opening set stumble or his capitulation in the decider. "He puts the ball wherever he wants", Daniel said.
"I was grateful to be out on the court after surgery that quickly but at the same time just didn't feel good at all".
"I was not even supposed to be here because of the surgery that was only five, six weeks ago", said Djokovic.More news: Kirk Cousins likely to sign with Vikings
More news: Nicole Kidman to lead another HBO series The Undoing
More news: American Idol Slips in Night 2, Easily Bested by The Voice
It was the earliest loss for Djokovic at Indian Wells since a first-round exit in 2006. Last year, he fell in the fourth round.
Daniel, who is ranked 109th in the world, advanced to the third round where he will face Gael Monfils of France.
Speaking after his upset win, Daniel said the Djokovic he bounded out of the tournament was not the one the tennis world is used to admiring. "So I was able to take advantage of it". "She's the best player I have ever played, and it was the biggest court I have ever played on".
World number one and defending champion Roger Federer's Indian Wells opener was marred by rain as the wet weather forced his contest with Federico Delbonis to be rescheduled.
The Serb was once the most dominant player around - winning four straight grand slam titles from 2015 to 2016 - but little of that scintillating form was on display when the 12-time grand slam victor was upset by Japanese qualifier Taro Daniel 7-6 (7-3) 4-6 6-1 in the second round in Indian Wells on Sunday.