Early on in the hit series, time-traveller Claire Beauchamp meets flame-haired herbalist Geillis Duncan (Lottie Verbeek), who ends up being tried and convicted of witchcraft in the fictional village of Cranesmuir.
But what fans might not know is that Geillis was named after and loosely based on a 16th century maid from Tranent who was herself accused of witchcraft.
The real Geillis Duncan was a teenage maidservant of bailiff David Seton who would become embroiled in a brutal episode in Scottish history known as the North Berwick Witch Trials.
The royal ship had been forced to turn back after nearly being capsized in a great storm. It would be weeks before James and Anne could set sail again. Rumours began to circulate that the storms were the product of witchcraft in an attempt to kill the king.
Back in Scotland, David Seton was beginning to question the fact that, despite her lack of education and tender years, his young employee seemed to possess a knack for alleviating the pain and suffering of those with incurable diseases.
It was also noted that Geillis would regularly wander off in the middle of the night for unknown purposes, further arousing the suspicions of her master, who was now making a link with the North Sea squalls that had threatened to take the king and queen's life.
Seton, along with his son, also named David, was regarded among Scotland's big wigs in the crusade against witchcraft, which was entering its most potent years since the enactment of the Scottish Witchcraft Act three decades earlier.
Convinced there was more to this maid of his than she was letting on, Seton began to interrogate Geillis in November 1590.
The young woman, who is believed to have been in her mid-teens at the time, was initially unresponsive to Seton's accusations of witchcraft, but she soon became vocal.
Determined to extract a confession, the deputy bailiff, aided by several male accomplices, proceeded to sadistically torture the girl, crushing her fingers until they splintered by use of the "pilliwinks", otherwise known as the thumbscrew, and "thrawed", with rope twisted and turned round her head.
Duncan was also stripped naked, shaved of all body hair and subjected to an intense physical examination, which modern academic Susan Dunn-Hensley describes as "tantamount to rape" and displaying the "most extreme and brutal form" of ill treatment towards women that a patriarchal society is capable of producing.
It was during this process of examination that Seton and his fellow tormentors claimed to have identified the "Devil's mark" on Duncan's throat, at which point the maid finally succumbed to making a confession.
A lengthy period of incarceration followed in which torture continued, resulting in Geillis reeling off a long list of others supposedly guilty of practising witchcraft.
As many as 60 alleged witches and warlocks from across Edinburgh and East Lothian were implicated, including Agnes Sampson, Agnes Thompson, Doctor Fian, Robert Grierson, Barbara Napier and Euphame Macalyean.
Most or all of the accused were tortured into confessing witchcraft, with the Devil’s mark found on their necks. The presence of Satan at a gathering that the accused had attended had also been recounted; a man dressed in black had allegedly instructed the witches that the king should be killed, an oath that was sealed by a kiss on the Devil’s buttocks.
A contemporary pamphlet, Newes from Scotland, details that Geillis claimed witches formed covens in North Berwick and Edinburgh where, through sorcery, they planned to bring about the demise of King James.
Geillis and others are said to have appeared in front of King James, who reportedly took an active role in the witch trials and even questioned the accused himself. His motivations for doing so are thought to have been at least partially political, with the king accusing Francis Stuart, the 5th Earl of Bothwell of plotting with the North Berwick coven to kill him. The earl was arrested for treason.
On the day of her execution on Edinburgh's Castlehill, Duncan and another alleged witch, Bessie Thomson, retracted their accusations (to no avail), each declaring that Seton and his accomplices had obtained their confessions by use of extreme force and torture.
The North Berwick Witch Trials gained widespread infamy in the decades that followed. Shakespeare adapted elements of the trials for use in Macbeth, with many of the rituals, including the three witches' spells which purposefully created storms to destroy ships, being directly inspired by the East Lothian incidents.
Witchcraft trials continued in Scotland for more than a century after the North Berwick episodes.
The last person to be tried and executed of witchcraft in Scotland was Dornoch woman Janet Horne in 1727.