Prince Andrew was so close to Jeffrey Epstein’s accused madam Ghislaine Maxwell he would secretly let her into Buckingham Palace up to four times a day, his former police protection officer claims.

Former London cop Paul Page told the Sunday Mirror that even before the Epstein scandal blew up from his child-sex conviction, Maxwell’s visits to the palace were kept hush-hush.

“We’ve got a guest coming for Andrew but the name is not to be entered in the book,” Page claims he was told by the Palace’s property managers the first time he saw Maxwell visit in 2001.

“Half an hour after that, me and my colleague walked through the garden to go back to the police lodge and he was having a picnic with her by the summer house, opposite the Queen’s ­bedroom window,” claimed the ex-cop.

Page — who was Andrew’s royal protection officer from 1998 to 2004 — told the UK paper that the British media heiress soon became a regular visitor.

“One of my colleagues saw her come in and out the Palace four times in one day.”

Maxwell has been accused in numerous court filings of procuring young girls for Epstein, her ex.

Maxwell — who is even accused of engaging in some of the sex — has long been rumored to be at the heart of ongoing investigations into Epstein’s circle after his death last August.

Andrew still spoke fondly of her in his disastrous BBC interview that ended with him booted from royal duties.

Page believes that as disastrous as the interview was, it suggests the royals were assured that the Duke of York would not be facing legal woes, despite reports that the FBI wants to interview him.

“If his legal team thought there was any possibility of indictments coming his way, they’d have shut the idea of doing the TV interview down,” Page told the paper. “So he must have had some guarantees that this isn’t going anywhere to publicly speak.”

He claims that the prince had “obviously been advised” to now distance himself from Maxwell, who has been in hiding since Epstein was arrested last summer on further serious sex charges.

“But I can’t see that Ghislaine is going to give any information against Andrew. I just can’t see it,” he insisted of the longterm loyal friends.

Buckingham Palace and Andrew have repeatedly denied all the allegations against the royal. Maxwell, who is still in hiding, has previously also denied any connection to abuse.

Buckingham Palace would not comment to the Sunday Mirror’s story, beyond pointing out that Page had lost his Met police job in 2009 when he was convicted over an investment fraud of almost $4 million. He insists his crime was unrelated to his job.