2017 Tour de France Champs-Elysees victor Dylan Groenewegen (LottoNL Jumbo) and Pascal Ackermann (bora-Hansgrohe) followed closely behind in the final bunch sprint, but the Colombian still had enough time to throw his hands in the air.
Gaviria has secured at least one victory at every stage race he's ridden this season, his last stage race the Tour of Britain, his last victory the one-day, Kampioenschap van Vlaanderen.
But he left his run until almost the last minute, kicking with just 100 metres to go.
"It was a very difficult stage with the wind and the speed in the bunch," Gaviria said. "My teammates did a great job and I'm glad I could repay them with this victory.
"It's always nice to win a race, especially a WorldTour one, and I'm happy to have added another win to the team's remarkable haul of successes this season."
Gaviria's teammate Rémi Cavagna continued QuickStep Floor's success by scooping up the most aggressive rider and KOM prizes after he joined the breakaway from the start of the 107km stage in Beihai, China.
Partyyyyyy!!!!! 😁😁😁😁#TourofGuangxi pic.twitter.com/T1AbEedaK6 — Quick-Step Cycling (@quickstepteam) October 19, 2017
He, Silvan Dillier (BMC), Nick Dougall (Dimension Data) and Andriy Grivko (Astana) took a maximum advantage of only 30 seconds until Cavagna pulled away after the final intermediate sprint, himself enjoying a minute's lead.
Cavagna was later joined by Jonathan Lastras (Caja Rural - Seguros RGA) on the final classified climb, the pair finally reeled in with three kilometres to go.