The 19-year-old Tsitsipas broke the ninth-seeded Serb's serve early in the third set and held serve from there to reach his first career ATP World Tour Masters 1000 quarterfinal.
"I feel very proud for me, myself, and my country. I'm putting Greece more deep into the map of tennis," Tsitsipas said. "I'm pretty sure I'm making my family proud, all of those people that are watching, my coach, my father. It was a very emotional win. I've never felt so many emotions after a victory."
Djokovic, a four-time Rogers Cup champion, faded late on a warm, breezy afternoon at Aviva Centre on the York University campus.
"Losing in this kind of tournament, it's not something I don't care about," Djokovic said. "It really frustrates me. But I have to accept it, deal with it, and move on. ... He just played better in the decisive moments. I had my chances to come back in the third set when I dropped my serve at 15-40. An easy forehand. I missed it, but that's sport. You have to deal with these kind of situations."
Tsitsipas set up match point with a scorching cross-court winner before completing the victory in 2 hours, 17 minutes.
"I knew he had some issues in some particular shots in his game, I would say. So I was waiting and I grabbed him like a bulldog and stuck there and executed, I executed my plan," Tsitsipas said. "I knew that at some point he's going to break, and I just patiently waited for this moment and it happened."
Top-ranked Rafael Nadal beat Swizterland's Stan Wawrinka 7-5, 7-6 (4) in a night match delayed by rain late in the first set. Nadal, playing his first event since losing to Djokovic in the Wimbledon semifinals, will face sixth-seeded Marin Cilic of Croatia.
"Very positive victory for me against a very tough opponent," Nadal. "That's what I needed, a match like this to be a little more confident. Just happy to be in the quarterfinals."
Cilic beat 11th-seeded Diego Schwartzman of Argentina 6-3, 6-2.
Tsitsipas will face second-seeded Alexander Zverev of Germany, the defending champion coming off a tournament victory last week in Washington that included a semifinal win over Tsitsipas. The 21-year-old Zverev beat Russia's Daniil Medvedev 6-3, 6-2 for seventh straight match win and tour-high 43rd of the year.
"I feel physically pretty well. I feel like I'm playing well," Zverev said. "I get into a rhythm of playing matches one after another, and right now, I'm in that rhythm."
Fourth-seeded Kevin Anderson of South Africa and fifth-seeded Grigor Dimitrov of Bulgaria set up another quarterfinal. Anderson topped qualifier Ilya Ivashka of Belarus 7-5, 6-3, and Dimitrov beat American Frances Tiafoe 7-6 (1), 3-6, 7-6 (4).
In the other quarterfinal, Karen Khachanov of Russia will play Robin Haase of the Netherlands. Khachanov beat eighth-seeded John Isner of the United States 7-6 (5), 7-6 (1), and Haase topped Canadian Denis Shapovalov 7-5, 6-2.