Ciphers, Hashes & PasswordsLast updated: 2026-09-26

XOR Calculator

Calculate XOR using Hex or UTF-8 input and a known repeating key. Inspect result bytes and text with this browser-based learning tool.

Open My tools

Conversion workspace

Key bytes repeat across the input. The key cannot be empty.

Input, keys and output stay in this page and are cleared on reload.

Examples and how it works

XOR produces 1 when two bits differ. This tool repeats your key bytes across the input. Applying the same key again restores the original bytes.

Input: Hex · key: Hex 01

Input
40 43 42
Output
ABC

Input: UTF-8 · key: Hex 01

Input
ABC
Output
@CB

Choose the input and key formats separately. Hex key “01” is one byte; UTF-8 key “01” is two character bytes and gives a different result. Keys must be 1–1024 bytes. Unknown keys are not recovered automatically.

ShareXfB!L

How to use

  1. 1

    Choose input and key formats

    Select Hex or UTF-8 independently for the input and the key.

  2. 2

    Enter a known key and data

    Enter a 1–1024-byte key and the input, then press Convert. Key bytes repeat from the beginning.

  3. 3

    Inspect text and Hex

    Check the resulting text and Hex bytes. Bytes remain available even if they cannot be decoded as UTF-8.

Features

  • Independent Hex and UTF-8 formats
  • Repeating keys of 1–1024 bytes
  • Text and Hex result views

Use cases

Learning data representations

Transform original samples to learn data representations.

Details

Input is limited to 1 MiB measured as UTF-8. Input and output are processed in this page, are not uploaded or saved, and disappear on reload.

Keys are not uploaded or saved. Key bytes repeat with the first key byte aligned to the first input byte.

FAQ

How do I reverse XOR?

Apply the same key to the result bytes again, using the same format, repetition and starting position.

Can I decode without knowing the key?

This calculator requires a known key. It does not perform automatic key recovery or brute force.

Are Hex 01 and text 01 the same key?

No. Hex 01 is one byte. UTF-8 text 01 is two bytes, 30 31.

All processing happens in your browser. Your files are never uploaded.

Did you know?

XOR with the same key twice restores the original bytes: a XOR k XOR k = a.

Optional usage measurement settings

Only with your consent, a random browser ID and tool/learning events are sent to measure return visits. This is pseudonymous measurement. Inputs, answers, keys, files and search terms are excluded. Consent expires after 90 days. Declining does not limit any feature.

Measurement is off.

Retention and privacy