Jonathan Day, the director of events for British Cycling Ventures, said the route was the “news fans have been waiting for” so they could plan where to watch the race.

He said: “We have worked closely with all our stakeholders to design a fantastic route that will ignite the race and create a memorable spectacle for all involved.

“The route brings unique challenges to the riders, while delivering a backdrop which shows the best of Britain.”

Borders councillor Scott Hamilton said: “This will be the first time that we have ever hosted the final stage of the Tour, so it will be a fantastic occasion.

“I am sure that we’ll see a large crowd in Earlston, enjoying not just the racing but other entertainment and activities throughout the whole day.”