When season three of “The Crown” premieres Sunday on Netflix, the year is 1964, it’s election day, and Queen Elizabeth II is dealing with a problem that seems straight out of the future.

Over breakfast, Prince Phillip informs his wife that Harold Wilson, the likely new prime minister, is rumored to be a Russian mole.

“That’s ridiculous,” replies the Queen, now played by Olivia Colman. “Who did you hear that from?”

“A friend of mine at the lunch club,” the prince says. “He had a whole theory about Wilson being turned on a trade mission to Russia.”

The queen doesn’t tell Prince Phillip to bugger off, but she does say that MI5 — the British counterintelligence service — would know if that was true, stopping his election in its tracks.

“Unless they never expected him to get this far,” the prince replies. “No one did.”

It cannot be a narrative accident that one of television’s most critically acclaimed shows did a ripped-from-the-headlines reference to the 2016 presidential election of Donald Trump, who is still dogged by allegations that he is a Russian agent.

But the story line isn’t just a riff on Trump’s election. In keeping with the show’s gripping use of history to personalize the queen and other royals, the episode exposes rumors and fears of betrayal among British government officials and leaders, including Winston Churchill.

Those fears publicly emerged a decade ago in “The Defence of the Realm,” an authorized history of MI5 by historian Christopher Andrew. The agency kept a file on Wilson throughout his years as prime minister, fearing that his previous ties to Eastern European businessmen and shady KGB affiliates left him exposed to bribery or worse.

When the revelations emerged in 2009, the historian told the Times of London “that Wilson was the only serving prime minister to have a permanent Security Service file.”

Sometimes, history really sounds familiar.

Anyway, Wilson was cleared by both the MI5 and the show’s writers, who use the episode to tell the startling story of a real life Russian mole on the queen’s staff.

His name: Anthony Blunt.

His palace job: surveyor of the queen’s art.

His spy job: member of the Cambridge Five, a spy-ring that included British intelligence agent Kim Philby, considered one of the most devastating double-agents in history.

Blunt was turned by the Soviets in the 1930s, then went on to work for MI5 during World War II, passing along still undisclosed secrets.

While compressing some aspects of his story, the show accurately depicts the bizarre circumstances of his unmasking.

After American authorities are tipped off about him, they tip off their British counterparts, who decide — with the queen’s apparent blessing — to extract a confession and, in an effort to avoid embarrassment, keep the entire sordid affair secret.

Blunt even goes on working as an art historian — on the show and in real life.

What “The Crown” doesn’t reveal is what happened 15 years later, when Blunt’s identity as a spy was revealed by Andrew Boyle, a Scottish journalist, in his book “The Climate of Treason.”

Blunt held a news conference more or less admitting his betrayal. Prime Minister Margaret Thatcher even appeared before Parliament and officially disclosed Blunt’s identity.

Her dramatic comments stunned the country and helped solidify the nickname given to her by the Soviets — “The Iron Lady.”

“There is no doubt that British interests were seriously damaged by his activities,” Thatcher said.

Thatcher even detailed what the queen knew (seemingly all of it) and when (as soon as the government knew).

“The queen’s private secretary asked what action the queen was advised to take if Blunt confessed,” Thatcher said. “He was told that the queen was advised to take no action.”

She didn’t — not then, and not on Netflix.

Read more Retropolis: