Hash Generator

Type or paste text and every hash updates as you go. Turn on HMAC to sign it with a key. The text and the key stay on this page; nothing is sent anywhere.

How it works

A hash function turns any amount of data into a short, fixed-size fingerprint. The same input always gives the same hash, and a change of a single character gives a completely different one. You cannot run it backwards to get the text out again.

Your text is turned into bytes with UTF-8 and then hashed with SHA-1, SHA-256, SHA-384 and SHA-512 by the browser’s own Web Crypto. The browser deliberately has no MD5, because MD5 is broken, so this page carries its own small MD5 for the cases where an old system still asks for one.

HMAC mixes a secret key into the hash. Only someone who has the key can produce the same result, which is how webhooks and APIs prove a message came from who it says. Everything is worked out on your device: the text and the key never leave the page.

How to use it

  1. 1 Type or paste into the Text box. The hashes appear below and update as you type.
  2. 2 Pick Hex or Base64 under Output, depending on what the other system expects.
  3. 3 To sign the text with a secret, turn on HMAC (keyed hash) and type the Key.
  4. 4 Press Copy next to the hash you need.

Good to know

  • Use SHA-256 unless something tells you otherwise. MD5 is shown as not secure, checksums only, and SHA-1 as weak, because both can be made to collide on purpose.
  • Never store passwords with a plain hash, even SHA-512. Use a slow password hash such as Argon2, scrypt or bcrypt, which a hash generator is not.
  • A trailing space or a newline changes the hash. If your result differs from another tool’s, check for invisible whitespace and for the text encoding.
  • HMAC is not offered for MD5 here. Use HMAC-SHA256, which is what nearly every webhook signature uses.
  • Hex and Base64 are two spellings of the same bytes. A SHA-256 is 64 hex characters or 44 Base64 characters.

Browser support

  • Chrome 94 and later
  • Firefox 93 and later
  • Safari 16.4 and later
  • Edge 94 and later

These are the oldest versions with everything the tool uses. They are worked out from the tool itself, so they change when it does.

Version numbers checked on 2026-09-04.

One letter, a whole new hash: SHA-256 and HMAC worked through

The quickest way to understand a hash is to watch one. Type abc into the box above. Its SHA-256 is ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad. That is the answer printed in the official SHA-2 standard, so it is also a good way to check that any hashing tool, this one included, is doing the right thing. The same three letters always give exactly this value, on every computer, in every language.

Now change the last letter and type abd. The hash becomes a52d159f262b2c6ddb724a61840befc36eb30c88877a4030b65cbe86298449c9. Nothing in it resembles the first one. Change only the case of the first letter instead, Abc, and you get 06d90109c8cce34ec0c776950465421e176f08b831a938b3c6e76cb7bee8790b, different again. This is called the avalanche effect: flipping one bit of input flips about half the bits of output. It is why a hash works as a fingerprint. Two files that differ by one byte cannot share a SHA-256 by accident, and there is no way to nudge the input towards a hash you want.

The same box shows the older algorithms too. MD5 of abc is 900150983cd24fb0d6963f7d28e17f72 and SHA-1 is a9993e364706816aba3e25717850c26c9cd0d89d. They are shorter, and both are broken in the sense that matters: researchers can build two different inputs with the same MD5 or the same SHA-1 on purpose. They are fine for spotting a corrupted download and wrong for anything an attacker might want to forge. That is why the browser’s Web Crypto refuses to do MD5 at all, and why this page labels it.

A plain hash proves that data has not changed, but not who sent it, because anyone can compute it. HMAC fixes that by folding a secret key into the calculation. The standard test case from RFC 4231 uses the key Jefe and the message "what do ya want for nothing?". Turn on HMAC (keyed hash), type Jefe as the Key and that sentence as the Text, and HMAC-SHA256 comes out as 5bdcc146bf60754e6a042426089575c75a003f089d2739839dec58b964ec3843. Change the key to Jeff and it becomes b756ec8c1f600eb277ee3f04163f581bd1c7e361f34a0727ad79c844ffc4bb83. A server receiving a webhook does exactly this: it recomputes the HMAC with its copy of the key and accepts the message only if the two values match.

Output format is a spelling choice, not a different hash. The SHA-256 of abc in Base64 is ungWv48Bz+pBQUDeXa4iI7ADYaOWF3qctBD/YfIAFa0=, the same 32 bytes as the hex above, written in 44 characters instead of 64. Pick whichever the other side expects; GitHub and Stripe signatures use hex, Subresource Integrity uses Base64.

Two limits are worth being plain about. A hash is not encryption, so it hides nothing that can be guessed: the SHA-256 of a common password is in every lookup table online. And a fast hash is the wrong way to store passwords, because fast is exactly what an attacker wants. For passwords use a deliberately slow function such as Argon2 or bcrypt. For checking data, signing messages and building fingerprints, SHA-256 and HMAC-SHA256 are what you want, and all of it is computed here on your device.

Frequently asked questions

Can a hash be decoded back into the text?

No. A hash keeps no copy of the input. Sites that claim to "decrypt" MD5 or SHA-1 simply look the hash up in a list of hashes of common words and passwords, which is why short or common text is not protected by hashing it.

Why is MD5 marked as not secure?

Since 2004 it has been possible to make two different inputs with the same MD5, and today it takes seconds on a laptop. It still catches accidental damage, which is why download pages publish it, but it cannot prove nobody tampered with something.

What is the difference between a hash and an HMAC?

Anyone can compute the SHA-256 of a message, so a plain hash proves nothing about who sent it. An HMAC also needs the secret key, so a matching HMAC shows the sender knew the key and the message was not changed on the way.

Why does my result differ from another tool?

Almost always the input differs: a newline at the end, a different text encoding, or Windows line endings. This page hashes exactly the characters in the box, as UTF-8, with nothing added.

Is my text or key sent to a server?

No. The hashing runs in your browser with its built-in Web Crypto, plus a few lines of JavaScript for MD5. You can go offline after the page loads and it keeps working.

Related tools

Your files are processed on your device and are not uploaded. You can verify this in your browser’s developer tools under the Network tab.