A 19-year-old man from Southampton who was in possession of "an offensive weapon" was captured shortly after 8:30 a.m. local time and remains in custody, the police said.
According to the police statement, officers from Thames Valley and the Metropolitan Police responded to the security breach within minutes. The man did not enter any buildings, the police said.
"The man has been arrested on suspicion of breach or trespass of a protected site and possession of an offensive weapon. He remains in custody at this time," Thames Valley Police Superintendent Rebecca Mears said in the statement. "Members of the Royal Family have been informed about the incident," she added.
The 95-year-old monarch was celebrating Christmas at Windsor Castle after making the decision not to travel to Sandringham, her usual Christmas destination, because of the pandemic.
She was accompanied at Windsor by her son, Prince Charles, and Camilla, the Duchess of Cornwall.
The Queen delivered her annual Christmas broadcast from the Windsor Castle, dedicating much of the traditional address to Prince Philip, her husband of 73 years who died in April at the age of 99.
While not common, intrusions into Royal palaces do occasionally happen. Perhaps the most famous incident dates back to 1982 when a man named Michael Fagan, who was 31 at the time, climbed a wall of Buckingham Palace, crawled through an open window and made his way to the bedroom of Queen Elizabeth II, who was sleeping.
The Queen was unharmed, although the intrusion sparked a serious questions about the palace security, especially when it emerged that her repeated attempts to summon help were ignored.
In 2004, a fathers' rights campaigner dressed as Batman evaded security to stage a protest on a Buckingham Palace balcony. Jason Hatch, a Fathers 4 Justice campaigner, used a ladder to scale the perimeter fence before climbing onto the balcony, where the royals appear on ceremonial occasions such as the wedding of Prince William and Catherine in 2011. Stand-up comedian Aaron Barschak had highlighted lax security by gate-crashing Prince William's 21st birthday party at Windsor in 2003.