Chris Froome conceded four seconds to Romain Bardet on the Col d’Izoard but took another step towards his fourth Tour de France title as Warren Barguil won stage 18.
Froome was alongside Bardet on the finish line but it was the Frenchman who finished third behind Barguil and Darwin Atapuma to collect four bonus seconds and trim his deficit in second place to 23 seconds.
Colombian Rigoberto Uran, who began the day level with Bardet on the general classification, was a further two seconds back on the road, and now trails Froome by 29 overall.
CLICK HERE FOR TOUR DE FRANCE GUIDE
Though Froome has seen his advantage cut slightly, the main goal was to retain yellow on the final summit finish of this year’s Tour.
The Team Sky rider must now defend it over relatively flat territory on Friday’s stage to Salon-de-Provence before Saturday’s time trial in Marseille where he is expected to gain time.
For Barguil the stage victory – his second of this year’s Tour – underlined his superiority in the king of the mountains classification, which he has mathematically wrapped up, needing only to safely make it to Paris.
But others suffered on the climb. Italian national champion Fabio Aru was dropped again, conceding over a minute as the former yellow jersey in this race slipped to fifth on general classification, behind Froome’s team-mate Mikel Landa and almost two minutes adrift of the race lead.
Bury’s Simon Yates conceded another 25 seconds to South African rival Louis Meintjes in the young riders’ classification but the Orica-Scott man still holds the white jersey by a margin of two minutes and six seconds.
Irishman Dan Martin was active in forcing the pace on the Izoard, and finished within 19 seconds of Bardet and Froome to retain sixth place overall.
The 179.5km stage from Briancon saw a 54-man breakaway go up the road early on but did not come to life until the imposing climb of the Col d’Izoard, 14.1km long at an average gradient of 7.3 per cent, as it took the peloton to a height of 2,360m.
Aru’s Astana team-mate Alexey Lutsenko had a lead of more than four minutes over the yellow jersey group as he started the climb solo – having attacked the fracturing breakaway – but the race was about to be blown to pieces.
Team Sunweb’s Barguil attacked alongside Spanish veteran Alberto Contador around six kilometres from the top and swiftly distanced the main contenders, who stayed focused on each other.
Sky tried to tease Bardet (AG2R La Mondiale) and Uran (Cannondale-Drapac) into making a move as they sent Landa up the road shortly after.
Bardet took the bait with three kilometres to go but Froome followed him and briefly dropped him on the short descent at Casse Deserte, two kilometres from the top.
For a moment it appeared the race was over as he swiftly gapped the others, but the distances were deceptive and instead the decisive move came when Bardet attacked with 400 metres left
That was enough to get Bardet – runner up to Froome 12 months ago – four extra seconds and solo ownership of second place.
Final leading positions after Stage 18, (Briancon-Izoard – 179.5km):
1 Warren Barguil (Fra) Team Sunweb at 4hrs 40mins 33secs
2 Darwin Atapuma (Col) UAE Team Emirates at 20secs
3 Romain Bardet (Fra) AG2R La Mondiale
4 Christopher Froome (Gbr) Team Sky at same time
5 Rigoberto Uran (Col) Cannondale-Drapac at 22secs
6 Mikel Landa (Spa) Team Sky at 32secs
7 Louis Meintjes (RSA) UAE Team Emirates at 37secs
8 Daniel Martin (Irl) Quick-Step Floors at 39secs
9 Simon Yates (Gbr) Orica-Scott at 59secs
10 Alberto Contador (Spa) Trek-Segafredo at 1min 9secs
11 Nairo Quintana (Col) Movistar Team at 1min 18secs
12 Carlos Betancur (Col) Movistar Team at 1min 22secs
13 Fabio Aru (Ita) Astana Pro Team at same time
14 Tony Gallopin (Fra) Lotto Soudal at 1min 37secs
15 Brice Feillu (Fra) Team Fortuneo – Oscaro at 1min 54secs
16 Mikel Nieve (Spa) Team Sky at 2mins 15secs
17 Alexey Lutsenko (Kaz) Astana Pro Team at 2mins 54secs
18 Andrew Talansky (USA) Cannondale-Drapac at 3mins 1secs
19 Bauke Mollema (Ned) Trek-Segafredo at same time
20 Serge Pauwels (Bel) Dimension Data at 3mins 4secs
Leading general classification after Stage 18:
1 Christopher Froome (Gbr) Team Sky at 78hrs 8mins 19secs
2 Romain Bardet (Fra) AG2R La Mondiale at 23secs
3 Rigoberto Uran (Col) Cannondale-Drapac at 29secs
4 Mikel Landa (Spa) Team Sky at 1min 36secs
5 Fabio Aru (Ita) Astana Pro Team at 1min 55secs
6 Daniel Martin (Irl) Quick-Step Floors at 2mins 56secs
7 Simon Yates (Gbr) Orica-Scott at 4mins 46secs
8 Louis Meintjes (RSA) UAE Team Emirates at 6mins 52secs
9 Warren Barguil (Fra) Team Sunweb at 8mins 22secs
10 Alberto Contador (Spa) Trek-Segafredo at 8mins 34secs
11 Damiano Caruso (Ita) BMC Racing Team at 13mins 41secs
12 Nairo Quintana (Col) Movistar Team at 13mins 52secs
13 Mikel Nieve (Spa) Team Sky at 23mins 11secs
14 Alexis Vuillermoz (Fra) AG2R La Mondiale at 23mins 33secs
15 Emanuel Buchmann (Ger) Bora-Hansgrohe at 31mins 1secs
16 Brice Feillu (Fra) Team Fortuneo – Oscaro at 35mins 6secs
17 Carlos Betancur (Col) Movistar Team at 36mins 25secs
18 Serge Pauwels (Bel) Dimension Data at 37mins 31secs
19 Tiesj Benoot (Bel) Lotto Soudal at 40mins 49secs
20 Bauke Mollema (Ned) Trek-Segafredo at 47mins 3secs