XOR Cipher

Encrypt and decode with multi-byte XOR - hex, text, or Base64 I/O. Includes a key analyzer with byte-frequency chart.

Input
Examples
Click to load (input + key)
Text XOR text key: Hello, World! / KEY
Hex ciphertext / text key - recover plaintext
Single-byte XOR (key=0xff) - bit-flip
Output
Key Analyzer
Key (hex)
-
Length
-
Entropy
-
Output byte frequency
How it works

XOR is symmetric - the same operation encrypts and decrypts. A multi-byte key repeats across the plaintext (Vigenère-style XOR). Entropy near 8 bits/byte suggests encrypted or random data; low output entropy with a short key indicates a weak cipher vulnerable to frequency analysis.

To decrypt, paste the ciphertext as input, use the same key, and XOR again - the plaintext is recovered.

Security note
XOR with a truly random key of equal length (one-time pad) is theoretically unbreakable. With a short repeating key it is a weak cipher, vulnerable to frequency analysis and known-plaintext attacks. Do not use single-byte or short repeating XOR keys for real encryption.
Examples