Xerobit

xxHash Generator: Compute XXH32 and XXH64 Digests

Enter text or hex bytes and a seed to compute its xxHash as XXH32 or XXH64. xxHash is a very fast non-cryptographic hash used for checksums, hash tables and deduplication. Results show in hex and decimal and run in your browser.

Text is hashed as UTF-8 bytes. Choose Hex bytes to hash raw bytes.

Result

  • Hash (hex)
    b1fd16ee
  • Hash (decimal)
    2986153710
  • Variant
    XXH32 (32-bit)
  • Input length
    11

    bytes

How to use the xxhash generator

  1. Type or paste your data into the Input field. Pick Hex bytes to hash raw bytes instead of text.
  2. Set the Seed (default 0). XXH32 accepts 0 to 4,294,967,295 and XXH64 accepts 0 to 18,446,744,073,709,551,615.
  3. Choose XXH32 for a 32-bit hash or XXH64 for a 64-bit hash.
  4. The xxhash result updates as you type, as a big-endian hex digest (the form the reference tool prints) and as a decimal number.

How the xxhash algorithm works

The xxhash family uses prime multipliers and bitwise rotations to mix input bytes rapidly. For XXH32, four 32-bit accumulators are initialized from the seed and five specific primes (PRIME32_1 through PRIME32_5). Input is processed in 16-byte stripes; each stripe updates all four accumulators by multiplying, adding, and rotating bits. After all full stripes are consumed, the accumulators are merged, remaining bytes are folded in, and a final avalanche step ensures every output bit depends on every input bit.

XXH64 follows the same structure but operates on 64-bit words with 32-byte stripes and its own set of five 64-bit primes. It processes more data per loop iteration with wider registers, so it is usually faster on 64-bit processors and produces a longer digest with fewer accidental collisions.

Reference values for common inputs

Use this table to check your own implementation. All values use seed 0 and are shown as the canonical big-endian hex digest.

InputXXH32XXH64
(empty)02cc5d05ef46db3751d8e999
a550d7456d24ec4f1a98c6e5b
abc32d153ff44bc2cf5ad770999
message digest7c948494066ed728fceeb3be

When to use xxhash instead of cryptographic hashes

Cryptographic functions like those in the SHA-256 generator or MD5 hash generator are designed to resist deliberate collision attacks. They are computationally expensive by design. The xxhash algorithm trades that resistance for raw throughput, making it ideal for hash tables, database indexing, file deduplication, network packet checksums, and build-system caching.

If you need to verify data integrity against an active adversary, use a cryptographic hash. If you need to map millions of keys to buckets per second, xxhash is the better choice. Other fast non-cryptographic options include MurmurHash, FNV, and Adler-32.

Understanding the seed parameter

The seed initializes the internal state of the hash. The same input hashed with different seeds gives unrelated outputs. This is useful for hash tables, where a random per-process seed makes hash-flooding denial-of-service attacks harder without changing the algorithm.

In this tool the XXH32 seed is a 32-bit unsigned integer (0 to 4,294,967,295) and the XXH64 seed is a 64-bit unsigned integer (0 to 18,446,744,073,709,551,615), matching the reference implementation. Decimal and 0x hex notation both work. Record the seed with the hash, because the same input will not match without it. For example, "abc" with XXH32 and seed 1 gives aa3da8ff instead of 32d153ff.

Common mistakes and edge cases

A frequent source of mismatches is byte order in the printed result. The canonical digest of xxHash is big-endian, which is what the reference xxhsum tool and this page print. A library that returns an integer and a tool that prints its bytes in memory order on a little-endian machine can look reversed. The decimal row shows the plain integer value.

Another pitfall is the input encoding. This tool hashes text as UTF-8, so an accented letter is two bytes. A UTF-16 string, as used internally by JavaScript and .NET, hashes differently; enter those bytes as hex instead.

What this tool does not do: it implements the classic XXH32 and XXH64 functions only, not the newer XXH3 and XXH128, which give different values. It hashes pasted text or hex rather than files, and very large pastes use browser memory. Never use xxHash for passwords or signatures, as it offers no resistance to deliberate attacks.

Worked examples

ExampleInputResult
Empty string, seed 0, XXH32Input format: text; Seed: 0; Variant: xxh32Hash (hex): 02cc5d05; Hash (decimal): 46947589; Variant: XXH32 (32-bit); Input length: 0
Hello World, seed 0, XXH64Input: Hello World; Input format: text; Seed: 0; Variant: xxh64Hash (hex): 6334d20719245bc2; Hash (decimal): 7148569436472236994; Variant: XXH64 (64-bit); Input length: 11
Custom seed 2654435761Input: test; Input format: text; Seed: 2654435761; Variant: xxh32Hash (hex): a9c14438; Hash (decimal): 2848015416; Variant: XXH32 (32-bit); Input length: 4
Raw bytes as hexInput: 00 ff 10; Input format: hex; Seed: 0; Variant: xxh32Hash (hex): 14a9ab49; Hash (decimal): 346663753; Variant: XXH32 (32-bit); Input length: 3

FAQ

Is xxhash cryptographically secure?

No. The xxhash family is designed for speed, not security. It does not provide collision resistance or preimage resistance. Use SHA-256 or SHA-3 for cryptographic needs.

What is the difference between XXH32 and XXH64?

XXH32 produces a 32-bit hash from 16-byte stripes and XXH64 produces a 64-bit hash from 32-byte stripes. XXH64 is usually faster on 64-bit CPUs and has far fewer accidental collisions.

Does the seed change the hash output?

Yes. Different seeds produce unrelated hash values for the same input. The default seed is 0, which matches the published test vectors.

Can I hash raw bytes with this tool?

Yes: switch the input format to Hex bytes and enter the bytes, for example 00 ff 10. The tool does not read files, so a file must be pasted in as hex.

Why do my results differ from another xxhash implementation?

Check the seed, the byte encoding of your input (UTF-8 versus UTF-16) and whether the other tool uses XXH3 or XXH128, which give different values. Also check whether it prints the result as a big-endian digest or as a little-endian integer.

Is my data sent to a server?

No. The computation happens entirely in your browser using JavaScript. Nothing is uploaded anywhere.