The Prince of Wales has told GCHQ staff the country owes them a great debt for their “utterly essential” work.
Prince Charles was visiting the Cheltenham base of the UK’s intelligence, security and cyber agency as part of centenary celebrations.
He toured the building and received a number of top secret briefings.
The Prince, who is patron of GCHQ, MI6 and MI5, told staff the nature of their job meant their achievements were rarely made public.
“Few people in this country will ever know just how great a debt we all owe you,” he said.
“But for those privileged enough to understand something of what you do, the difference you make to our security, our prosperity and to the defence of our values is both clear and invaluable.”
Prince Charles also visited the GCHQ museum to view a number of items relating to the agency’s work to protect members of the royal family.
These included a codebook developed for the royal household in 1939 and a Royal Navy codebook to set up a secure communications path when he was serving at sea.
Earlier this year, it emerged Prince William had spent three weeks on work placements with MI5, MI6 and GCHQ.