Sagan pipped Alexander Kristoff in a photo finish to win the stage from Moirans-en-Montagne to Bern.
Race leader Chris Froome came home in a much-reduced peloton at the end of the 209km stage to maintain his advantage in the yellow jersey competition.
Slovak Sagan claimed his third victory at the Tour this year and seventh in total in the third photo finish of the 2016 race.
This victory ensured this will go down as Sagan's best Tour yet, having also held the yellow jersey for three days during the first week.
He won the second and 11th stages before this, but his third stage victory outstrips the two gained in each of 2012 and 2013.
And as he's well on his way to winning a fifth straight green jersey, the 26-year-old is enjoying his best Tour yet and the best season of his career.
He was world champion back in September and then won his first prestigious “Monument” one-day classic at April's Tour of Flanders.
— MISSBETTY_BOOO (@MissBetty_Booo) July 18, 2016
Fans turned out under sunny skies to see the peloton pass through Switzerland on its way to Bern.
Swiss rider Fabian Cancellara finished Monday's stage just a few miles from his home.
It was an emotional return to Switzerland for the 35-year-old, who is riding his last Tour and will retire from cycling at the end of this season.
— Actu velo (@flash_velo) July 18, 2016
The cyclists will now enjoy a rest day in the Swiss capital before setting off on stage 17 on Wednesday, which will finish at the stunning Emosson dam.