How does the Vigenère cipher work?
Every letter of the message is shifted as in the Caesar cipher, but by a number that changes each time: it is given by the matching letter of a key, repeated as often as needed. A counts as 0, B as 1, up to Z as 25.
With the key LEMON, “ATTACKATDAWN” becomes “LXFOPVEFRNHR”. The two Ts at the start, encrypted with E and then M, do not give the same letter.
Encrypting and decrypting
Enter the key in the settings, then type the message on either side. The key only moves on over the letters A to Z: digits, spaces, punctuation and accented letters stay as they are, unless you remove accents before encrypting.
Finding an unknown key
Paste the encrypted message without a key. For every key length up to 20 letters, the tool finds the shift that gives each column letter frequencies close to those of the page language, then ranks the resulting keys. The “Use” button applies the one you choose.
The method needs text: a few hundred letters give good results, a few words give none. A key as long as the message cannot be recovered.
A historical cipher
Long held to be unbreakable, it has been broken since the 19th century. It is for puzzles and study, not for protecting data: use modern encryption such as AES for that.
Frequently asked questions
Who invented this cipher?
It is named after Blaise de Vigenère, a 16th-century French diplomat, but the idea of a key using several alphabets had been described before him, notably by Giovan Battista Bellaso.
Why is the suggested key almost right?
With few letters, one column can mislead the statistics. If a word can be guessed, correct the wrong letter in the “Key” box.
Is a longer key safer?
Yes, it resists better, but only a random key as long as the message, used once, would be unbreakable.
Are my message or key sent anywhere?
No. Everything is computed in your browser, and the key is not saved.