The King has begun his official stay in Scotland by receiving the keys to the City of Edinburgh, which is celebrating its 900th anniversary.

Charles took part in the Ceremony of the Keys in the garden of the Palace of Holyroodhouse, his official residence in the Scottish capital.

He was welcomed by the Lord Provost, City of Edinburgh councillor Robert Aldridge, who presented the keys on a red velvet cushion which Charles symbolically touched.

King visits Scotland for Holyrood Week
The King receives the keys to the City of Edinburgh from Lord Provost Robert Aldridge at the Palace of Holyroodhouse (Andrew Milligan/PA)

Mr Aldridge told the King, after he arrived by helicopter with the Queen: “We, the Lord Provost and members of the City of Edinburgh Council, welcome Your Majesty to the capital city of your ancient and hereditary kingdom of Scotland and offer for your gracious acceptance the keys of Your Majesty’s good City of Edinburgh.”

Charles gave the traditional reply: “I return these keys perfectly convinced that they cannot be placed in better hands than those of the Lord Provost and councillors of my good City of Edinburgh.”

Each year the monarch traditionally spends a week based at the Palace of Holyroodhouse, known as Holyrood Week or Royal Week in Scotland.

King visits Scotland for Holyrood Week
Charles inspects the guard of honour during the Ceremony of the Keys at the Palace of Holyroodhouse (Andrew Milligan/PA)

This year’s Holyrood Week is shorter then in previous years because the General Election has meant the royal family has postponed any engagements “which may appear to divert attention or distract from the election campaign”.

Before the ceremony, the palace’s garden was transformed into a parade ground, where the King met senior military and uniformed figures including Chief Constable of Police Scotland Jo Farrell, before receiving a royal salute and inspecting a Guard of Honour of soldiers from Balaklava Company, 5 Scots.

Also lined up were the Royal Company of Archers, who serve as the sovereign’s ceremonial bodyguard for Scotland – a role first created in 1822 for King George VI.

King visits Scotland for Holyrood Week
Soldiers from the Royal Regiment of Scotland took part in the ceremony in Edinburgh at the start of the King’s trip to Scotland for Holyrood Week (Andrew Milligan/PA)

The Band of the Royal Regiment of Scotland and the Pipes and Drums of 2nd Battalion Royal Regiment of Scotland were on parade for the occasion.

The King walked past the Guard of Honour, casting his eye over the servicemen and stopping to talk to some of them, and he also chatted to members of the military bands.