XXTEA Encryption
Encrypt text, files, or URL content online with XXTEA using text keys with zero padding and truncation, or 128-bit keys encoded as UTF-8, Hex, or Base64. Read more
XXTEA encryption online
XXTEA, or Corrected Block TEA, encrypts a variable-length array of 32-bit words with a 128-bit key. Unlike a conventional fixed-size block cipher, its number of cycles depends on the number of words. This tool wraps the input length into the encrypted word array so the original byte length can be restored after decryption.
How to use this tool
Choose text, a local file, or URL content. With Text Key, the UTF-8 key bytes are zero-padded to 16 bytes or truncated after 16 bytes. With Custom Key, supply exactly 16 bytes using UTF-8, Hex, or Base64. Encrypt and copy or download the ciphertext in the selected encoding.
Matching cipher parameters
Use the same key bytes and byte-to-word conversion in the receiving implementation or XXTEA decryption. This page uses little-endian 32-bit words and appends the original byte length before encryption. Other XXTEA libraries may use a different string encoding, endianness, or length-inclusion convention and therefore produce different results.
XXTEA does not expose a block mode, padding option, IV, salt, or passphrase KDF here. Hex and Base64 only represent the resulting ciphertext bytes.
Security warning
XXTEA does not provide authentication and has not received the standardization and deployment profile of modern authenticated encryption. Published cryptanalysis of full XXTEA also documents a chosen-plaintext attack with an impractically large but lower-than-brute-force query requirement. Use it for required compatibility, not new security designs; prefer AES encryption in a suitable authenticated format.
Frequently asked questions
Why can I not decrypt the result elsewhere?
Compare the 128-bit key bytes, UTF-8 conversion, little-endian word order, original-length field, plaintext encoding, and ciphertext encoding. “XXTEA” alone does not fully specify these wrapper choices.
Does encryption detect tampering?
No. XXTEA ciphertext can be modified without an authentication tag. A surrounding protocol must verify integrity and origin.