Sagan held on through a brutal late climb – whose gradients briefly hit 20 per cent – to contest the finish, where things flattened out near the line. After a challenging 210km of aggressive racing, no one else in the lead group came close to matching his speed in the final few hundred metres.
Thibaut Pinot moved up to second overall a few hours into the stage when Adam Yates (Orica-Scott) abandoned the race, and the Frenchman then put a small dent into his deficit to race leader Nairo Quintana (Movistar) by earning six bonus seconds at the line.
Quintana takes a 50-second lead over Pinot into Monday's sixth stage.
To subscribe to the Cyclingnews video channel, click here.