Skip to content
Developer

Hash Generator

Generate SHA-1, SHA-256, SHA-384, SHA-512 hashes via Web Crypto.

hashshasha256sha512digest
Loading tool…

Recommended tools

Affiliate links — we may earn a commission if you sign up.

About the Hash Generator

The Hash Generator computes SHA-1, SHA-256, SHA-384, and SHA-512 digests of any text simultaneously, using the Web Crypto API entirely in the browser — nothing you type leaves the page. Type or paste text into the input field and all four hashes recalculate live as lowercase hexadecimal strings, which makes it trivial to compare digest lengths (20, 32, 48, and 64 bytes) and to spot-check a value against checksums published elsewhere. The tool ships preloaded with the classic pangram The quick brown fox jumps over the lazy dog so you can verify the well-known SHA-256 vector at a glance. Each algorithm gets its own output panel with its own download button — sha1.txt, sha256.txt, sha384.txt, or sha512.txt — and a stat strip reports input bytes plus digest lengths in bytes. Empty input is handled gracefully with a prompt instead of an error. Because hashing is one-way and collision-resistant, this is the right tool for fingerprinting a string, comparing two versions of a value without exposing it, or generating a cache key — though never for passwords, which need salted KDFs like bcrypt.

Hand-written guide

Examples

Input
The quick brown fox jumps over the lazy dog
Output
SHA-1: 2fd4e1c67a2d28fced849ee1bb76e7391b93eb12
SHA-256: d7a8fbb307d7809469ca9abcb0082e4f8d5651e46d3cdb762d02d0bf37c9e592
SHA-384: ca737f1014a48f4c0b6dd43cb177b0afd9e5169367544c494011e3317dbf9a509cb1e5dc1e85a941bbee3d7f2afbc9b1
SHA-512: 07e547d9586f6a73f73fbac0435ed76951218fb7d0c8d788a309d785436bbb642e93a252a954f23912547d1e8a3b5ed6e1bfd7097821233fa0538f3db854fee6
Note: The preloaded pangram produces all four well-known test vectors at once — a quick way to confirm the tool matches your own hashing code.
Input
abc
Output
SHA-256: ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad
Note: Every keystroke recomputes all four digests live; the SHA-256 of abc is the famous vector from the FIPS test suite.
Input
password123
Output
SHA-1: cbfdac6008f9cab4083784cbd1874f76618d2a97
Note: Digests are lowercase hex — useful for comparing against hashes published by registries or logs, though never for storing passwords.

How to use

  1. 1

    Type or paste the text to hash into the Input text textarea.

  2. 2

    Watch all four result panels update live as you type.

  3. 3

    Compare digest lengths with the stat strip — SHA-1 len, SHA-256 len, and SHA-512 len in bytes.

  4. 4

    Use Clear to empty the input; the panels then show a prompt instead of hashes.

  5. 5

    Download any single digest with its own download button (sha1.txt, sha256.txt, and so on).

Common use cases

  • Verifying that a downloaded string matches a published SHA-256 checksum.
  • Fingerprinting configuration values to detect drift without storing plaintext.
  • Generating cache keys from canonicalized request strings.
  • Comparing digest lengths when choosing between SHA-256 and SHA-512 for a new system.
  • Confirming your server-side hash implementation matches the browser output during development.
  • Creating one-way tokens for lightweight de-duplication of log messages.

Best practices

  • Never use plain SHA digests for passwords — they are fast and unsalted; use bcrypt, scrypt, or Argon2 instead.
  • Treat SHA-1 as legacy: use it only for checksums and compatibility, never for security decisions.
  • Hash canonical inputs — differences in whitespace, casing, or key order change the digest completely.
  • When comparing digests by hand, check the first and last eight characters rather than the whole string.
  • Remember hashing is one-way: a digest cannot be reversed, which is why it suits fingerprinting rather than storage.
  • For integrity-sensitive data, prefer HMAC (keyed) over plain hashes so attackers cannot recompute the value.

Tips

  • Watch the Input bytes stat — it reveals hidden whitespace that changes your digest.
  • Use the pangram as a smoke test: if your SHA-256 output differs from the well-known vector, your input has extra characters.
  • Download the digest files instead of copying from the page to avoid trailing-space mistakes.
  • When comparing hashes visually, compare the first and last 8 hex characters — they are enough to catch a mismatch.

Frequently asked questions

The tool runs the four Web Crypto digest calls in parallel on every change, so you can compare algorithms without switching modes. It also makes the byte-length differences obvious: 20 bytes for SHA-1, 32 for SHA-256, 48 for SHA-384, and 64 for SHA-512.

Explore more developer tools

Browse the full collection of developer tools on the hub, or jump back to all categories.

Related tools