Mark Cavendish won the final stage of the Tour of California in Sacramento on Sunday night.

Cavendish, who has a property in Ongar, emerged from the pack to beat Tinkoff's reigning world champion Peter Sagan and Alexander Kristoff of Katusha to the line in a sprint finish.

Julian Alaphilippe (Etixx-QuickStep) finished safely in the pack to secure the general classification win.

Cavendish was short of Dimension Data team-mates in the final stages of the 138km stage around the state capital after a tough day's racing, but he latched on to Sagan's wheel and timed his sprint to perfection.

"We had to use our whole lead-out to catch the break, so in the end it was a bit a case of free styling," Cavendish said on his team's website. "I was on Sagan's wheel and know this finish really well. I've won here before and knew that, if was in the right position I should win here."