There have been several town walls around Edinburgh, Scotland, since the 12th century. Some form of wall probably existed from the foundation of the royal burgh in around 1125, though the first building is recorded in the mid-15th century, when the King's Wall was constructed. In the 16th century the more extensive Flodden Wall was erected, following the Scots' defeat at the Battle of Flodden in 1513. This was extended by the Telfer Wall in the early 17th century. The walls had a number of gates, known as ports, the most important being the Netherbow Port, which stood halfway down the Royal Mile. This gave access from the Canongate which was, at that time, a separate burgh.
