The event was first recorded in the city in 1579 and held regularly until 1718
About 10,000 people lined the streets of Edinburgh on Sunday to see an ancient riding tradition revived after a 63-year absence.
The Riding of the Marches, which dates back to the 16th Century in the city, was last held in 1946, when there was a one-off event to mark the end of WWII.
The event saw 250 horses and riders make a seven-hour journey from the Braid Hills to the Royal Mile.
Lothian and Borders Police pipe band played at the finale.
Representatives from the 28 Scottish towns which continue to celebrate a summer riding festival also joined the finale in the heart of the city's Old Town.
Edinburgh's Lord Provost, George Grubb, said: "The Riding of the Marches is a fantastic addition to the huge range of events taking place in Edinburgh during 2009, the Year of Homecoming."
The riding tradition, known as "common riding" in the Borders, is believed to date as far back as the 12th Century, when Scottish towns were granted a charter, effectively creating the birth of the town.
The event was first recorded in the capital in 1579 and was held on a regular basis until 1718, where the purpose was to inspect the boundary markers of the city to stop unlawful encroachment and protect the integrity of the city boundary.
A number of towns, particularly in the south of Scotland, continue with the practice to this day, and the events form the centrepiece of many local festivals.