Chris Froome is set to win the 2016 Tour de France after Spaniard Jon Izaguirre won stage 20 to Morzine.
Team Sky's Froome safely negotiated the treacherous, wet descent off the Col de Joux Plane alongside his rivals to lead by four minutes and five seconds over Frenchman Romain Bardet ahead of Sunday's traditional parade into Paris.
Much of the penultimate 146.5km stage from Megeve was played out in heavy rain but Froome, who crashed on Friday's stage to Saint-Gervais Mont Blanc, was able to avoid late drama after dominating this Tour.
Froome will become only the eighth man, not including the disgraced Lance Armstrong, to win three or more Tours after his victories in 2013 and 2015, and is the first to defend the Tour title since Miguel Indurain in 1995.
He will join Philippe Thys, Louison Bobet and Greg LeMond on three titles, and will now have his eyes set on five-time winners Eddy Merckx, Bernard Hinault, Jacques Anquetil and Indurain.
Izaguirre was the last survivor of what had been a 37-man breakaway earlier in the day, racing clear of Vincenzo Nibali and Jarlinson Pantano on the sodden descent to take his first Tour de France stage win.
Behind, there was little drama with none of Froome's main rivals prepared to risk crashing in the slippery conditions.
The contenders came home more than four minutes after Izaguirre, with Froome allowing himself half a smile as he celebrated with his team-mates on the approach to the line.
His primary emotion might well have been one of relief as the foul weather set a potential trap in the Alps.
The Briton has looked a cut above all of his rivals since early in the second week of this Tour, but Friday's crash had been a reminder that nothing was won yet.
He began the day sporting bandages on his knee and elbow from that spill, and would not have relaxed for a moment knowing he had to face the long, technical descent into Morzine before any celebrations could begin.
The descent has a nasty reputation in any conditions, but the rain perhaps helped Froome in discouraging those around him from even attempting an attack.
Nairo Quintana, seen as Froome's main pre-Tour rival, is set for third place, four minutes and 21 seconds behind Froome. It will be the Colombian's third podium finish in the Tour after he finished second to Froome in 2013 and 2015.
Adam Yates, the 23-year-old Briton, is fourth, four minutes 42 seconds down and safe in the white jersey as the best young rider.
Although there is one day still to go in the Tour, the final stage to Paris is traditionally a procession into the city before the sprinters have their fun on the Champs-Elysees, with the battle for yellow considered over.