Vigenère Cipher Encoder & Decoder

Encrypt and decrypt text with a keyword-based Vigenère cipher.

Ad placeholder (leaderboard)
Enjoying the tools? Go Pro for £4.99 (one-time) and remove all ads — forever, on this device. Remove ads — £4.99

The Vigenère cipher is a classic polyalphabetic substitution cipher: instead of shifting every letter by the same amount like a Caesar cipher, it uses a repeating keyword so each position is shifted by a different value. Described by Giovan Battista Bellaso in 1553 and later misattributed to Blaise de Vigenère, it resisted casual codebreaking for 300 years. This tool encrypts and decrypts text with any keyword, entirely in your browser.

How it works

The keyword is first cleaned to letters only and lower-cased, then repeated across the letters of your message (spaces, digits and punctuation pass through and do not advance the keyword). Each plaintext letter is shifted by the alphabet position of the matching keyword letter — A = 0, B = 1, … Z = 25 — wrapping around modulo 26. To decrypt, the tool shifts in the opposite direction (by 26 − shift). Letter case is kept; non-letters are left untouched.

Example

Encrypting ATTACKATDAWN with the keyword LEMON:

PlaintextATTACKATDAWN
KeyLEMONLEMONLE
Shift114121413114121413114
CipherLXFOPVEFRNHR

The result is LXFOPVEFRNHR. Decrypting it with the same keyword returns the original message. Everything happens in your browser, so your message and keyword never leave your device.

Ad placeholder (rectangle)