The Movistar rider attacked at the base of the final climb to take the win at the end of the 170km stage from Eschenbach to Arosa.
Astana's Jakob Fuglsang finished second while race leader Richie Porte (BMC) was third, both finishing together at 22 seconds.
Porte's overall lead was cut to 17 seconds with Quintana second and Wilko Kelderman (Sunweb) is third.
"I wanted to see what my real form was, and fortunately, I'm feeling great at the moment," Quintana said. "The team's work was really good, with everyone taking efforts from the very beginning of the stage and as far as they could.
"We put [Daniele] Bennati to push at the front of the bunch on the flat before the climb, trying to keep the breakaway close and taking advantage from Víctor's position to bridge back and get further.
"[Victor] De la Parte was fundamental up there on the flat between the climbs, pushing as much as he could for as long as possible. And in the end, it was my task. Mikel [Landa] was also trying to attack the GC group and destroy the pace by BMC, just like I asked him to do."
Quintana built a gap on of half a minute to begin his 25km long-range strike at race leader Richie Porte (BMC).
Porte's team-mate Greg van Avermeat, already active in the massive 31 rider break of the day, proved crucial in support up to the final few kilometres before leaving his team leader to chase down Quintana with Fuglsang.
"That was a long climb and I don't think we ever expected Nairo to go that early but that's racing," Porte said. "I wasn't expecting an attack so early on the bottom of the climb but I had Tejay [van Garderen] there with me and then a super Greg Van Avermaet, who did a fantastic job for me.
"I didn't stress too much and I gave it everything so, hats off to Nairo, he was super strong today and I think he thoroughly deserved the stage win. I lost some time on the GC but I'm still looking forward to the time trial.
"We've still got to get through tomorrow's stage but I think normally I am not a bad time trialist so, I'm here to try and win this race and I think it is looking good now. I'm happy with where my form is at. I was good yesterday as well and I hope to have the legs that I need for Sunday."
Richie Porte and Jakob Fuglsang gassed it in chase of Nairo Quintana. (Getty) Source: Getty