The royal couple are said to be "upset" after Chief Inspector John Hourihan decided to leave in order to become chief of security at Broadmoor psychiatric hospital.
Hourihan worked for Scotland Yard's Royalty Protection Branch, and had been with with the pair since 2008. He attended several high-profile events, including last year's Far East visit.
"John is a very respected police officer with the Royalty and Diplomatic Protection Department who has served Scotland Yard and the Royal Family with distinction," a source told The Mirror.
"During his career with S014 he worked as the Personal Protection Officer for the Earl and Countess of Wessex and latterly heading up security for the Duke and Duchess of Cambridge.
"He was brought in to use his wealth of experience to establish the security team surrounding the Duchess after her engagement to Prince William was announced, and has travelled with them extensively.
"But after serving as a Scotland Yard officer for 30 years he has decided to move on and try something new.
"He was snapped up by a private security company as a consultant and is now assisting the company's security operations at Broadmoor Hospital."
An insider close to Prince William said: "John was a fabulous guy who was always there where they needed him. Calm, astute and experienced, he was a top man. They will miss him but wish him well in the future."
Kate Middleton was recently reported to have said that she is hoping for a baby boy, while Prince William wants a girl.
The Duchess of Cambridge - who is currently expecting her first child with Prince William - is said to not yet know the gender of the baby.
View all of today's best celebrity pictures - Photo gallery: