The 22-year-old also moved into second place in the overall standings behind Primoz Roglic after pipping the Slovenian and Rui Costa in a sprint finish on the final climb at Romont.
Thomas, one of the race favourites, was in sight of victory at one stage but he almost collided with Michael Woods and his chance was gone, the Welshman eventually classified in 14th place, just 0.3sec behind the French rider.
"I felt good all race but I didn't believe too much," said Gaudu.
"I just told myself that until the end and until I pass the line, victory is not possible, that someone will catch me."
Leading 3rd stage results
1. David Gaudu (FRA/FDJ) 3hr 50min 53sec, 2. Rui Costa (POR/UAE) at 0, 3. Primoz Roglic (SLO/JUM), 4. Michael Woods (CAN/EF1), 5. Felix Grosschartner (AUT/BOR) all same time , 6. Guillaume Martin (FRA/WGG) 3, 7. Emanuel Buchmann (GER/BOR) 3, 8. Davide Villella (ITA/AST) 3, 9. Carl Fredrik Hagen (NOR/LOT) 3, 10. Damien Howson (AUS/MIT) 3.
14. Geraint Thomas (GBR/INE)
1. Primoz Roglic (SLO/Jumbo) 12hr 23min 02sec, 2. David Gaudu (FRA/FDJ) at 6, 3. Rui Costa (POR/UAE) 8, 4. Felix Grosschartner (AUT/BOR) 19, 5. Geraint Thomas (GBR/INE) 20, 6. Carlos Betancur (COL/MOV) 21, 7. Damien Howson (AUS/MIT) 25, 8. Steven Kruijswijk (NED/JUM) 27, 9. Michael Woods (CAN/EF1) 28, 10. Emanuel Buchmann (GER/BOR) 29.