The 28-year-old was leading the race and looking at the prospect of another day in yellow after an armchair ride on a sleepy stage for the peloton on the 183-kilometre stage from Gap to Privas.
However, French television cameras had caught Alaphilippe taking a bidon from the side of the road with just over 17 kilometres remaining to the finish.
Rule 4.10.4 of the UCI regulations regarding road races forbids feeding within the final 20 kilometres of the stage, with a 20-second penalty and a 200 Swiss franc fine the nominated penalty.
"That's a rookie error," McEwen said.
"He was caught red handed - 20 second penalty. That's what the rule book states and that's what they gave him.
SBS Tour de France host Mike Tomalaris labelled the error "embarrassing".
The time penalty means Alaphilippe is now 16 seconds down on the new race leader, Adam Yates (Mitchelton-Scott).
It is the Australian team's first time in yellow since they had a four-day stint in 2013, spread between Australian Simon Gerrans and South African Daryl Impey.
The Tour de France continues tonight with a 191-kilometre stage from Le Teil to Mont Aigoual, with the broadcast starting from 9:00pm (AEST) on the SBS ŠKODA Tour Tracker App, then from 9:30pm (AEST) on SBS and SBS On Demand.