For kings and queens the palace was a richly decorated and furnished place of comfort.
The rooms witnessed key events in their lives and Scotland’s history.
Queen Mary of Guise, last defender of the Auld Alliance with France and champion of the Catholic faith against the Protestant Reformation, died there in 1560.
It was here too that her daughter, Mary Queen of Scots, gave birth to James VI in in 1566. The birth was difficult and one of Mary’s companions supposedly tried using magic to transfer the birth pangs onto a servant.
The Mary Room and Birth Room (within the Royal Palace) will be closed on Tues 24 July until 12 noon.
The Mary Room (within the Royal Palace) will have a partial closure in place from 1 to 9 August.
The Birth Room (within the Royal Palace) will be closed from 1 to 9 August. A video will be set up in the Anti-Chamber and will show Thomas Payne's live painting from the Birth Room. No painting will take place on Sat 4 and Sun 5 August.
This was the start of a remarkable life, as he became king of Scotland soon after his first birthday in 1567 and united the crowns of Scotland and England in 1603.
He made an emotional return in 1617 to celebrate his golden jubilee – the birth chamber was redecorated for the occasion. This tiny room is a highlight for many modern castle visitors.
Charles I was the last sovereign to stay at the palace, sleeping there on 19 June, 1633, the night before his Scottish coronation.
The birthplace of James VI is located in the Eastern range of Crown Square. Entry is via a door in the south-east corner, adjacent to the Crown Gift Shop.