ELI5: Explain Like I'm 5

Vigenère cipher

Vigénere cipher is a way to secure a message so that only people who know the secret code can understand it. It involves using a special kind of code to arrange the letters of the message in a certain way.

Imagine that you have a message that you want to keep secret from someone. To do this, you can use a Vigénere cipher. First, you pick a 'key word'. This could be any word you choose, like 'ABC'. Then you write down the letters of your key word over and over until it's the same length as your message.

Say your secret message is 'Hello' and you chose the key word 'ABC'. You would write the letters of 'ABC' over and over until it's the same length as your message. So you would write 'ABCABC' underneath the word 'Hello'.

Now you look at the letter of your secret word that is above each letter of your code (ABCABC). Each letter gives you a number, starting from A=0, B=1, etc. So A above H is 0, B above E is 1, and so on. Now you add the number for each letter in the secret word to the letter of the secret message. For example, for H (which is 0) you would add 0 to H, so it remains H. For E (which is 1) you would add 1 to E, so the new letter would be F. Then for L (2) you would add 2 to L, so the new letter would be N. So the end result would be 'NFNOH'.

To decode the message, you would do the exact same thing but instead of adding the numbers, you would subtract them. So if you see a 'N', you would subtract 2 (because 2 was added to L) to get back to 'L'. Then you would subtract 1 from 'F' to get back to 'E', and so on.

That's how Vigénere ciphers work in a nutshell!
Related topics others have asked about: