UTILS.
Private by default
Vig

Vigenère Cipher

Encrypt or decrypt text with the classic keyword-based Vigenère cipher.

Your files stay on this device

Files are processed in your browser, never uploaded. The site downloads code and assets to run the tools. No accounts or trackers.

Use Download to save this tool as one HTML file for offline use.

Privacy →
— output appears here —

About this tool

Vigenère Cipher encrypts and decrypts text by shifting each letter by an amount taken from a repeating keyword. With the keyword LEMON, the first letter moves by L (11 places), the second by E (4), and so on, cycling back to L after the fifth letter. Enter a message, set the keyword and press encrypt or decrypt; the result can be copied with one click.

Only the 26 English letters A to Z and a to z are enciphered, and their case is kept. Everything else, including spaces, digits, punctuation, accented letters and emoji, is copied through unchanged, and the keyword does not advance on those characters. The keyword is cleaned the same way: characters that are not English letters are dropped, matching ignores case, and if nothing is left the tool asks for a keyword with letters. Decrypting applies the opposite shifts, so you need the same keyword that was used to encrypt.

The output updates as you type and keeps the mode you last pressed, so editing the message or keyword while decrypting re-runs the decryption. The Vigenère cipher dates from the sixteenth century and was long thought unbreakable, but it falls to frequency analysis once the key length is guessed, especially with a short keyword or a long message. Use it for puzzles, teaching and games, never to protect anything private; for that, use proper encryption such as AES.

Frequently asked questions

What happens to spaces and punctuation?
Non-letter characters pass through unchanged, and the keyword does not advance on them, so only letters are enciphered.
Is the keyword case-sensitive?
No. The keyword is treated case-insensitively, while the case of each message letter is preserved in the output.
How do I decrypt a message?
Paste the ciphertext, enter the same keyword and press decrypt. The tool stays in decrypt mode while you edit either box, until you press encrypt.
Is the Vigenère cipher secure?
No. It is a historical cipher that can be broken by hand or by a short program, so use it for fun and learning only.

More tools