A letter written on Napoleon Bonaparte’s orders in 1809 sat unread for 217 years, its contents locked inside a cipher nobody could break. Now an artificial intelligence system has done in hours what generations of cryptographers could not, cracking the code and revealing what the emperor was so determined to hide.
The message was sent by Eugène, Napoleon’s stepson, to General Auguste de Marmont, one of his most senior commanders. Marmont was stationed in what is now Croatia, cut off from the main French armies as the Habsburg Empire prepared to go to war with France to win back lost territory. The letter carried details of French and Austrian troop movements on the eve of that conflict, information too sensitive to risk sending in plain language.
For over two centuries the cipher key needed to unlock it was lost, leaving historians with 1,300 characters of letters and old words that meant nothing to anyone. Cryptographers over the years had managed to work out just 33 of those characters by hand, a painstaking process with no real end in sight.
Carter Church, an AI engineer at cybersecurity company SentinelOne, decided to try a different approach. He used OpenAI’s GPT-6 Astra system, an advanced version of the technology behind ChatGPT, to transcribe and decrypt the message. The AI spent six hours mapping the characters against the cryptographers’ earlier work, then used a technique called simulated annealing, a form of trial and error in which candidate words are tested against Marmont’s own known writing until the right fit emerges.
Church said he had never attempted to crack a cipher before and had been inspired by seeing an AI model decode a 1941 German army message. In that earlier case, developer Carter Leffen simply asked GPT-6 Astra to find and decrypt an unsolved Enigma message, and it managed the task in about 10 hours.
What the Napoleon letter finally revealed was a commander’s instructions on the brink of war. It gave Marmont the locations and strength of both the French and Austrian forces, and told him to prepare to march without being “intimidated by a few troops or a gathering of rabble”. It went further still, predicting Austria’s fate in blunt terms: “Austria will be attacked at once on every side. She is consequently hastening towards her ruin.”
History records that Marmont’s army did break free from its isolated position, part of a campaign that ended in French victory. What has changed is not the outcome but our view of it, now filled in by words the emperor’s own stepson once trusted to a code nobody alive was ever meant to read.
Researchers note the same capabilities could just as easily unmask anonymous writers today by matching patterns in their prose to real identities, a reminder that the tools cracking open the past are already reshaping how much privacy the present can keep.











