Skip to content

Hash Generator

Generate MD5, SHA-256 and SHA-512 hashes of any text at the same time, as you type, entirely in your browser.

Runs in your browser Free, no sign-up
Loading tool workspace...

What is Hash Generator?

A hash function turns any input into a fixed-length fingerprint. The same input always produces the same hash, a one-character change produces a completely different one, and the hash cannot be turned back into the input. That makes hashes useful for checksums, cache keys, deduplication and verifying that two values match.

This hash generator calculates three common hashes of your text at once: MD5 (32 hex characters), SHA-256 (64) and SHA-512 (128). They update as you type, and each has its own copy button. Text is hashed as UTF-8, so the results match command-line tools like sha256sum and the hashing functions in most programming languages.

How to use Hash Generator

  1. Type or paste the text you want to hash into the input box.
  2. The MD5, SHA-256 and SHA-512 hashes appear immediately, in lowercase hexadecimal.
  3. Click the copy icon next to the hash you need.
  4. To verify a value, compare the hash with the one you expected; hex hashes are not case-sensitive.

Key features

  • MD5, SHA-256 and SHA-512 calculated at the same time
  • Updates instantly as you type
  • UTF-8 hashing that matches md5sum, sha256sum and programming languages
  • Lowercase hex output with a copy button for each algorithm
  • SHA hashes computed with the browser's native Web Crypto API
  • Runs locally, so sensitive text never leaves your device

Common use cases

  • Checking that a configuration value or string matches an expected checksum
  • Generating cache keys, ETags or deduplication keys from content
  • Debugging request-signing code by comparing intermediate hashes
  • Producing test vectors for unit tests of hashing code
  • Learning how small input changes completely change a hash

Technical details & standards

Input text is encoded as UTF-8 before hashing. SHA-256 and SHA-512 (FIPS 180-4) are computed with the browser's Web Crypto API (crypto.subtle.digest); MD5 (RFC 1321) uses a JavaScript implementation, since Web Crypto does not include it. Results are shown as lowercase hexadecimal.

Hashes are exact: whitespace counts. A common reason for a mismatch with the command line is a trailing newline, because echo "text" | sha256sum hashes "text\n"; use echo -n to hash the text alone. Everything runs in your browser and nothing you type is transmitted.

Frequently asked questions

Is MD5 still safe to use?

Not for security. Practical MD5 collisions have existed since 2004, so attackers can craft two different inputs with the same hash. MD5 is still fine for non-adversarial jobs such as cache keys or spotting accidental changes; use SHA-256 when integrity matters.

Can a hash be reversed to recover the original text?

No. Hash functions are one-way. Short or common inputs can still be found by trying candidates against a precomputed table, which is why passwords must be stored with slow, salted algorithms such as bcrypt or Argon2, not plain SHA-256.

Why doesn't my hash match the one from the command line?

The inputs differ, usually by invisible whitespace. echo adds a trailing newline unless you use echo -n, and copied text can include extra spaces or Windows line endings (\r\n). Hashes are case-insensitive hex, so uppercase versus lowercase does not matter.

What is the difference between SHA-256 and SHA-512?

Both are SHA-2 hash functions and both are secure today. SHA-256 produces a 256-bit (64 hex character) hash and SHA-512 a 512-bit (128 hex character) hash. SHA-256 is the more common choice for checksums and signatures; SHA-512 can be faster on 64-bit processors.

Is my data safe?

Processing happens locally in your browser. Tool input is not sent to CodeUnpack servers.

Does it work offline?

Once the page has loaded, this tool can process input without an internet connection.