Compute DJB2, SDBM, and FNV-1a hashes

Compute a digest of text after choosing its encoding and display format.

freeworks offlinenothing uploaded
ToolString Hash
Input
Output
Put this on your own site

The frame below runs the same code as this page, in the reader's own browser. Nothing is sent to us, and nothing is sent to you.

Pick a dark background and the text and panels follow it, so the frame stays readable on a dark page.

Preview

How it works

The selected digest algorithm processes the UTF-8 bytes of the string and renders the resulting fixed-length bytes in the chosen encoding. A digest is deterministic for identical bytes but is not reversible text encryption.

  • UTF-8 is the web default; hex is readable while Base64 is more compact.

Worked example

Hash a String
Compute DJB2, SDBM, and FNV-1a hashes for a string
Input
											hello
										
Output
												DJB2:   f923099 (261238937)
SDBM:   28d19932 (684824882)
FNV-1a: 4f9f2cab (1335831723)
											

When to use this

Content fingerprints, cache keys, and reference-vector tests hash strings.

Edge cases

  • Unicode normalization changes the bytes before hashing.
  • A trailing newline creates a different digest.
  • A digest cannot be decoded back into the original string.

References