Edinburgh Castle has a history that dates back over 3,000 years. It has been a royal residence, a military stronghold, and a symbol of Scotland's independence.