Edinburgh (Edinburgh /ˈɛdɪnb(ʌ)ɹə/ in English and Scottish; Scottish Gaelic: Dùn Èideann) is the capital and a county of Scotland (United Kingdom). It is the second largest city in Scotland after Glasgow.
Located on the east coast of Scotland, on the banks of the Fjord of the River Forth and in the unitary local authority of the City of Edinburgh, it has been the capital of Scotland since 1437 and the seat of the Scottish government. It was one of the most important centers of education and culture during the Enlightenment thanks to the University of Edinburgh. Its districts The Old Town (old city) and The New Town (new city) were designated a World Heritage Site by UNESCO in 1995. According to the 2017 census it has a total population of 513,210 inhabitants.
Edinburgh is famous for its International Festival, the world's largest festival of live performances, and other festivals held more or less simultaneously in the summer, most of which are grouped under the name Edinburgh Festival. During the festival the population of the city doubles. Edinburgh is the second most visited city in the UK, after London, with approximately 13 million tourists a year.
The origin of the city's name is believed to come from the British Din Eidyn ('Fort of Eidyn'), from the days when it was just a fort. In the 1st century the Romans documented the Votadini as a local Brittonic tribe, and in the 12th century the ancient poem Y Gododdin mentions the celebrations of warriors in the 'great hall of Eidin'.
After being attacked and conquered by the Anglo-Saxon Bernicians, the name changed to Edim-burh, coming from the Anglo-Saxon and meaning "Edwin's Fort", in hypothetical reference to the 7th century King Edwin of Northumbria. However, it is highly unlikely that this is so, as the name predates King Edwin. The burg element is very common among Scottish city names and in all Germanic languages, as it names a class of city characterized by having grown around a central fortified structure, such as a fort or castle.
The first evidence of the city's existence as a separate entity from the fort is found in a 12th-century proclamation, generally believed to date from 1124, by David I of Scotland, granting land to the Church of the Holy Edinburgh Road. This suggests that the official existence of the city originates between the year 1018 (when King Malcolm II secured the Lothians from the Northumbrians) and the year 1124.
The proclamation refers to the recipients in Latin as "Ecclisie Sancte Crucis Edwin esburgensi", which could indicate that the person who issued the proclamation believed that Edwin of Northumbria was the original source of the city's name and derived the Latinization from what they believed it was the old name. It may also be that earlier, before the 11th century, the name was altered to include a "w". If this had been the case, it was soon to change anyway, for by the 1160s William I of Scotland used the name Edenesburch in a proclamation (again in Latin) confirming the 1124 donation by David I of Scotland.
Documents from the 14th century show that the name had already been transformed into its current form, with the exception of spelling differences (Edynburgh or Edynburghe), which were only common spellings at this time.
The town is affectionately nicknamed Auld Reekie, which means "Old Chimney" or "Old Smoky" in Scots. This is because during the times when wood and charcoal were the only fuels available, all chimneys put large amounts of smoke into the air. Auld Reekie was also referring to the appalling sanitary conditions that caused a huge foul odor throughout the city.
Some call Edinburgh the