Djokovic beat Haas 6-4 6-1 7-6 to progress to the quarter-finals where he will face Tomas Berdych.
Haas beat Djokovic at Wimbledon four years ago, and the world number one believes that his poor record against the German made the win even more satisfying.
"I had a bad record against him, I lost twice in 2009 against him and he is a grass-court specialist, so it was a tough challenge for me, but I played really well," Djokovic told reporters.
"I had to work hard, but I was serving well, returning exceptionally good in important moments.
"I had a minor setback when he broke me at 5-3 in the third set, but I am glad I closed it out."
Haas's break late in the third set was the first time that Djokovic has lost a service game all tournament.