Skip to content
Utilboxes

Hash Generator

Type or paste text to see its MD5, SHA-1, SHA-256, SHA-384 and SHA-512 hashes at once, in hex or Base64. Add a secret key to get HMACs for signing API requests and webhooks. Text is hashed as UTF-8, so results match sha256sum and other tools. Everything is calculated in your browser.

Runs entirely in your browser

Updated

How to use the Hash Generator

  1. 1Type or paste the text to hash.
  2. 2Choose hex or Base64 output, and upper-case hex if a system expects it.
  3. 3Tick HMAC and enter a secret key to get keyed hashes instead.
  4. 4Copy the hash you need with its copy button.

How it works

A hash function turns any input into a fixed-length fingerprint: SHA-256 always gives 256 bits, written as 64 hex characters. The same input always gives the same hash, and changing a single character changes it completely. It cannot be reversed to recover the input.

The SHA family is calculated with your browser's built-in Web Crypto API. MD5 is not part of Web Crypto, so it comes from the same WebAssembly library the file checksum tool uses.

Text is converted to UTF-8 bytes before hashing, exactly as typed. A trailing space or line break changes the result, which is the usual reason two tools seem to disagree — echo adds a line break unless you use echo -n.

HMAC combines a secret key with the message, as defined in RFC 2104, so only someone with the key can produce or check the value. It is offered for the SHA family, which is what APIs and webhook signatures use.

MD5 and SHA-1 have known collision attacks. They are fine for matching an existing checksum, not for security. Passwords should never be stored as plain hashes; they need a slow, salted algorithm such as Argon2 or bcrypt.

Everything runs in this page. Nothing you paste is transmitted, logged or stored, which is what makes it safe to drop a production payload in here while you are debugging.

Worked example

Hashing the text “abc” with SHA-256

  1. Input bytes (UTF-8): 61 62 63
  2. SHA-256 → ba7816bf 8f01cfea 414140de 5dae2223 b00361a3 96177a9c b410ff61 f20015ad (spaces added for reading)

Result: The standard test vector from the SHA-2 specification, so you can confirm the tool is correct.

Tips and common mistakes

  • Copy text without a trailing line break when you need to match a hash made elsewhere.
  • For webhook signatures, hash the raw request body exactly as received, before any JSON reformatting.
  • Compare hashes as lower-case hex unless the other system insists on upper case.
  • Do not use a fast hash such as SHA-256 alone to store passwords.

Frequently asked questions

Why is my hash different from another tool's?
Almost always because the input differs by an invisible character — a trailing space or line break, or a different text encoding. Here, text is hashed exactly as typed, as UTF-8.
Can a hash be decrypted?
No. A hash is one-way. Sites that claim to “decrypt” MD5 just look the hash up in lists of common inputs, which is why short or common inputs are not safe to hash on their own.
Which algorithm should I use?
SHA-256 for anything new. Use MD5 or SHA-1 only to match a checksum that was published that way.
How do I hash a file?
Use the File Checksum Verifier, which hashes files of any size in your browser and compares the result with a published checksum.
Is the text I hash sent anywhere?
No. Hashes are calculated in your browser, so you can hash API keys or test data without them leaving your device.
Why is HMAC not offered for MD5?
Browsers' Web Crypto API supports HMAC only with the SHA family, and modern APIs use HMAC-SHA256 or stronger. HMAC-MD5 is obsolete.