The 19-year-old Kyrgios, making his Wimbledon debut, clinched a fearless 7-6 (7/5), 5-7, 7-6 (7/5), 6-3 victory to become the first wildcard in 10 years to make the quarter-finals at the All England Club.
The young Australian dropped service just once but also broke only once during the four-set match, managing to pull off victory thanks to two tough tiebreaks.
Kyrgios, who recently said his aim was to be the world number one, is now the first player ranked outside the top 100 to defeat a world number one since Andrei Olhovskiy stunned Jim Courier in the Wimbledon third round in 1992.
He is also the first teen to accomplish the feat since Nadal himself beat Swiss legend Roger Federer at the French Open in 2005.
It was a performance of brutal inventiveness and uninhibited bludgeoning from a man who had had to save nine match points in his second round win against Richard Gasquet and his reward is a clash with Canada's Milos Raonic for a place in the semi-finals.
For Nadal it was a second such Wimbledon shock result in consecutive years.
In 2013, he was knocked out of the tournament on grass by Belgian world number 135 Steve Darcis.