Nibali (Astana) more than a minute and a half behind previous leader Tejay Van Garderen (BMC) at the start of the stage, pulled out all the stops to finish second behind Rui Costa (Lampre-Merida) and claim the race leader's yellow jersey.
"Frankly, I was looking for the stage victory more than the yellow-blue jersey. I think I'm crazy. Yesterday I told Michele Scarponi that I'd try to break away if I was going to feel good. He said ‘you're mad'," Nibali said.
"The day went well. I found an interesting company with riders of the caliber of Valverde, Rui Costa, Gallopin and Martin who had the same desire as I had.
"I didn't go for such a long breakaway since I rode in the young categories. But I want to make it up for the bad day I had yesterday.
"I needed to have at least one race at the front like today because my last race was quite a long time ago, it was the Tour de Romandie in April, after which I recovered from the early part of the season that didn't go that well for me. I've had a nice block of training in Tenerife with the team and I came to the Dauphiné looking for answers.
"I didn't get them yesterday, that's why I went on the offensive today. But I know by experience that it's not ideal to have a too good shape at the Dauphiné. Usually I come to this race looking for condition."
The 183km stage was raced in driving rain, but the 30-year-old Sicilian was undeterred as he attacked more than 110km from the finish in Villard-de-Lans.
He was part of a stellar breakaway group which featured Tony Martin (Etixx-QuickStep), Costa, Alejandro Valverde (Movistar) and Tony Gallopin (Lotto-Soudal).
By the time they were 40km from home, the quintet had opened up a three-and-a-half minute gap on the rest of the field and Nibali ended the day leapfrogging from 13th overall to take the overall lead.
He was 29sec ahead of stage winner Costa and 30sec up on Valverde, while Van Garderen found himself fifth, 42 sec adrift of Nibali.
Costa, 28, world champion in 2013, stole it at the last to snatch victory from Nibali, who looked spent in the finale but had the overall lead sewn up.
“We knew today's stage would be difficult. But we didn't know it would rain and be cold in addition to racing on a hard course,” Costa said.
“It started very fast and it never slowed down. At some stage, the peloton exploded. We went too fast in a downhill (col de la Croix-Haute), we saw a gap and we went flat out, after which I believe we've been flat out till the finish line.
“The final climb was hard, maybe less because of its gradient than the speed we rode at all day. Nibali went with two kilometers to go. I preferred to keep my own pace and handle the few strengths I had left. I never gave up my ambitions to win the stage but only with 300 metres to go, and certainly not before, I could foresee the possibility to win.
“Usually I ride the Tour de Suisse but in a discussion with the team, we thought it would be better to do the Dauphiné in order to be less tired at the start of the Tour de France.
“Initially I was supposed to take it easy and just see how my condition is. Yesterday, I wasn't at my best but today I felt better. And being away with top riders like Valverde and Nibali, it's enormous.
It's important to win my first stage at the Dauphiné. But I don't know if I'll be able to ride GC even though I'm second now. The legs will be tired after today but I'll try to do my best in the last two stages.”
Surprisingly Chris Froome (Sky) played no effective part in the stage, finishing 1min 21sec behind Nibali, who is looking to make history in the Tour de France warm-up event.
"Now that I'm in the lead, looking at defending it will be a hard task considering the two difficult stages to come and the strong riders who are still in contention," Nibali said.
"A few years ago I realized that no Italian has ever won the Dauphiné. It might be something special for me but I prefer to keep my feet on the ground and take it day by day."
The seventh and penultimate stage contains five major climbs along the 155km route from Montmelian to Saint-Gervais and ends with a mountain finish.
Stage 6: 183km, Saint-Bonnet-en-Champsaur - Villard-de-Lans
1 Rui Costa (POR) Lampre-Merida 4hr 29min 23sec
2 Vincenzo Nibali (ITA) Astana 0:00:05
3 Alejandro Valverde (ESP) Movistar 0:00:38
4 Tony Gallopin (FRA) Lotto-Soudal 0:00:39
5 Simon Yates (GBR) Orica-GreenEDGE 0:01:24
6 Daniel Martin (IRL) Cannondale-Garmin 0:01:46
7 John Gadret (FRA) Movistar 0:01:48
8 Tiesj Benoot (BEL) Lotto-Soudal 0:01:59
9 Chris Froome (GBR) Team 0:02:12
10 Benat Intxausti (ESP) Movistar
1 Vincenzo Nibali (ITA) Astana 22hr 34min 17sec
2 Rui Costa (POR) Lampre-Merida 0:00:29
3 Alejandro Valverde (ESP) Movistar 0:00:30
4 Simon Yates (GBR) Orica-GreenEDGE 0:00:35
5 Tejay Van Garderen (USA) BMC 0:00:42
6 Benat Intxausti (ESP) Movistar 0:00:57
7 Chris Froome (GBR) Sky 0:01:21
8 Tony Gallopin (FRA) Lotto-Soudal 0:01:29
9 Romain Bardet (FRA) AG2R 0:01:30
10 Daniel Martin (IRL) Cannondale-Garmin