Gemstones from the crown jewels were kept safe during the Second World War in a biscuit tin hidden at Windsor Castle, a BBC documentary will confirm.

It was known the precious stones had been taken to the Berkshire fortress in the early years of the war in case they fell into Nazi hands following an invasion, but there were few facts to the story.

Now a BBC One programme about the crown jewels and the Queen's coronation will reveal for the first time how the historic artefacts were secreted in a deep hole following orders from King George VI.

The gems, including the Black Prince's Ruby from the Imperial State Crown, were placed in the biscuit tin and buried under a sally port - a secret exit from the castle used in times of emergency.

The Queen, who spent her war years at Windsor Castle for safety, was aware of the general story but did not know the details until told by royal commentator Alastair Bruce, who presents the documentary due to be screened on Sunday.

Mr Bruce told the Times newspaper: "What was so lovely was that the Queen had no knowledge of it. Telling her seemed strangely odd."

The remarkable story was unearthed for the documentary by Oliver Urquhart Irvine, the librarian, and assistant keeper of the Queen's Archives.

The royal commentator told the paper how "an electric set of letters" from Sir Owen Morshead, the royal librarian, to Queen Mary, the mother of George VI, shed light on the mystery.

Sir Owen's documents describe how a hole was dug in chalk earth, which had to be covered to hide it from enemy bombers, and two chambers with steel doors created.

A trap door used to access the secret area where the tin box was kept still exists today.

In the documentary, the Queen also talks about the amusing trials and tribulations of being head of state - from the perils of wearing a heavy crown, to her robes sticking to a thick carpet pile.

The Queen speaks candidly and with humour about the experience of her own coronation and the symbolic importance of artefacts associated with the sovereign in the one-hour programme.

She jokingly states you cannot look down when wearing the Imperial State Crown, which weighs 2lbs 13oz (1.28kgs), as your neck would "break".

She also recounts how she was brought to a standstill when her robes ran against the carpet pile in Westminster Abbey during her coronation.

The Imperial State Crown is worn by the Queen when delivering her speech during the state opening of parliament, and, with the priceless artefact in front of her, she points out it has been reduced in height since her father King George VI wore it.

Looking at the crown, the Queen said: "Fortunately, my father and I have about the same sort of shaped head. But once you put it on, it stays. I mean, it just remains on."

Mr Bruce said the head has to be kept still when wearing it and the Queen agreed: "Yes. And you can't look down to read the speech, you have to take the speech up. Because if you did your neck would break, it would fall off.

"So there are some disadvantages to crowns, but otherwise they're quite important things."

The crown was made for George VI's coronation in 1937 and is set with 2,868 diamonds including 17 sapphires, 11 emeralds and hundreds of pearls, including four known as Queen Elizabeth I's earrings.

It also features a gemstone known as the Black Prince's Ruby, believed to have been worn by Henry V in his helmet at the Battle of Agincourt in 1415.

The Queen acceded to the throne on February 6 1952 when her father died unexpectedly in his sleep at Sandringham in Norfolk.

Despite the country being in the grip of post-war austerity, a glittering coronation was staged on June 2 the following year at Westminster Abbey.

The documentary features footage of the Queen processing through the Abbey and highlights how her coronation dress was embroidered in silk with pearls, and gold and silver bullion thread.

The Queen recounted: "Well, I remember one moment when I was going against the pile of the carpet and I couldn't move at all."

Mr Bruce said: "Really?" and the monarch replied: "Yes, they hadn't thought of that."

The documentary is part of the Royal Collection Season, a major partnership between the BBC and Royal Collection Trust, which also features the four-part television series Art, Passion And Power: The Story Of The Royal Collection.

The Coronation will be screened on BBC One at 8pm on Sunday.