However, Groenewegen - who won the final stage on the Champs Élysées previous year - seemed fresher and more powerful and beat all of his rivals by a sizeable margin.
"I'm happy with that, " Sagan said.
"I was following quite good wheels but it was choppy.
It makes this Tour de France a success for us already, and anything else is a bonus".
"I just keep trying, our backs are against the wall all the time here".
"In terms of his GC rivals, it puts the Dutchman 1'20" behind Team Sky's Geraint Thomas, while Adam Yates (Mitchelton-Scott) and Chris Froome are now 21 seconds ahead of the 2017 Giro d'Italia champion.
Days like these are referred to as "transfer" stages, for moving the Tour from one area to the next - from Brittany to north-central France in this case, as the race winds toward Sunday's highly awaited cobblestoned leg to Roubaix near the Belgian border.
Froome is 14th, 1:05 behind Van Avermaet.
Great French hope Romain Bardet (Ag2r) and last year's Giro d'Italia victor Tom Dumoulin (Sunweb) were the biggest losers among the overall favourites, losing 31 seconds and 53 seconds respectively.
170 riders started Stage 6 but it was Martin who triumphed despite taking an almighty gamble to sprint for the front. "I don't know what happened - maybe adrenaline - but I wasn't going to let anyone beat me".
As the climb wore on, a strong headwind and a dramatic last- minute chase by Pierre Latour of Ag2r saw Martin just hold on by a mere second to claim victory from the Frenchman on the line, with Alejandro Valverde of Movistar a further two seconds back in third.
"I was really relaxed all day - not over-confident, but looking forward to having a crack, looking forward to racing hard on the last climb".
Greg Van Avermaet held on to the yellow jersey he grabbed on Stage 3 and doubled his lead over Geraint Thomas to six seconds by winning an intermediate bonus sprint. It's challenging enough for the racers who specialize in the one-day spring classics over that terrain.
While the Colombian got a good jump, it was Groenewegen who came from behind with too much pace, beating the two-time stage victor by a few bike lengths in an emphatic victory.