Reference
What Is a Cipher?
A cipher is a rule for disguising text by changing or rearranging its letters, usually with a secret key, so only someone who has the key can read it.
Written and maintained by the CipherPad team at FusionStudios. Last updated 15 October 2026.
Cipher vs code
In one line: a cipher works on individual letters or bits by a rule, while a code replaces whole words, letters or ideas with other symbols looked up in a table or codebook.
The words cipher and code are often used loosely, but they mean different things. A cipher transforms each letter by a rule, such as shifting it along the alphabet. A code replaces entire words or ideas with other symbols, like a codebook that maps attack at dawn to a single word.
Morse code, despite its name, is really a way of representing letters as signals rather than hiding meaning, so it is an encoding. A Caesar cipher, which shifts letters to conceal a message, is a true cipher. The table below runs the same word through two ciphers and one code; every output is calculated by the same engine the translators use.
| Method | Type | HELLO becomes | To read it you need |
|---|---|---|---|
| Caesar cipher, shift 3 | Cipher | KHOOR | The secret shift, 3 |
| Vigenere cipher, keyword KEY | Cipher | RIJVS | The secret keyword, KEY |
| Morse code, no key | Code (an encoding) | .... . .-.. .-.. --- | Nothing secret: the chart is public |
The main types of cipher
Substitution ciphers replace each letter with another, like Caesar (a fixed shift), Atbash (a mirrored alphabet) or the pigpen symbol cipher. Vigenere is a polyalphabetic substitution: it uses a keyword so the shift changes as you go.
Transposition ciphers instead rearrange the letters without changing them. Modern computer ciphers combine substitution and transposition many times over, but the classic ciphers on this site are the perfect way to understand the ideas.
What are the different types of cipher and code?
It helps to split them into four families. Codes and encodings (Morse, binary, Base64) change the form of a message without hiding it. Classic ciphers (Caesar, Vigenere, Playfair, rail fence, affine, Atbash) genuinely conceal it using a rule and usually a key. Alphabets (braille, the NATO phonetic alphabet, pigpen) swap one symbol per letter for readability rather than secrecy. Word games (Pig Latin, leetspeak) simply rearrange or restyle letters for fun.
The table below sorts every translator on this site into those families, which is the quickest way to see what a given method actually does before you use it.
| Family | What it does | Examples |
|---|---|---|
| Codes | Not secret at all. These represent letters as signals, dots or bits so they can travel by radio, wire or touch. | Morse Code, Binary Code, Text to Binary, Binary to Text, Base64 Text |
| Classic ciphers | True ciphers. Each letter is replaced or moved by a rule, and often a key, so the message is hidden rather than just re-encoded. | Caesar Cipher, ROT13, Atbash Cipher, Vigenere Cipher, A1Z26, Tap Code, Pigpen Cipher, Playfair Cipher, Rail Fence Cipher, Bacon Cipher, Affine Cipher, Polybius Square |
| Alphabets | Letter systems. One symbol, word or cell per letter, designed to be read reliably rather than kept secret. | Braille, NATO Phonetic Alphabet |
| For fun | Word games. The transformation is obvious once you know it, so they are for play rather than privacy. | Pig Latin, Leetspeak (1337) |
How strong are the classic ciphers?
Weak, by design and by age. A Caesar cipher has only 25 possible keys, so trying all of them takes seconds. Any single-alphabet substitution, pigpen included, leaks letter frequencies: the most common symbol in an English message is almost always E. Vigenere resists that until the key length is found, then falls apart the same way.
That does not make them pointless. They are the clearest way to understand the two ideas every modern cipher still relies on, substitution and transposition, and they are the backbone of puzzle hunts, escape rooms and geocaching. For anything that genuinely needs protecting, use modern encryption instead.
Frequently asked questions
What does cipher mean? #
A cipher is a system for turning readable text into a disguised form by transforming each letter or bit according to a rule, so that only someone who knows the rule (and any key) can read it back. The word can also mean the disguised text itself, or the algorithm as a whole.
What is the difference between a cipher and a code? #
A cipher scrambles individual letters or bits by a rule. A code replaces whole words or phrases with other symbols, usually via a codebook. Caesar is a cipher; a codebook mapping phrases to numbers is a code.
Is Morse code a cipher or a code? #
Neither in the secret sense. Morse code is an encoding: it represents letters as dots and dashes using a public chart, so anyone with the chart can read it. Nothing is hidden, which is what separates it from a cipher such as Caesar.
What is the simplest cipher to learn? #
The Caesar cipher, which shifts every letter a fixed number of places. It is easy to understand, easy to use, and the classic first step into cryptography.
Are these ciphers secure? #
The classic ciphers here are for learning and puzzles, not for protecting real secrets. Modern encryption uses far more complex methods, but the ideas start here.
Keep exploring
Reference this tool
Mention this page in homework, a write-up or an article with this line:
What Is a Cipher? on CipherPad, retrieved on the date of your visit, https://cipherpad.dev/learn/what-is-a-cipher
The text on this page is licensed CC BY 4.0: you may share and adapt it, also commercially, as long as you credit CipherPad and link to the page.