FIPS 180-4 · TLS · Git · Bitcoin

SHA-2 hash generator

Current workhorse cryptographic hash family. Choose between SHA-224 (28 bytes), SHA-256 (32 bytes), SHA-384 (48 bytes), and SHA-512 (64 bytes). Uses Web Crypto API, client-side only.

0 chars
SHA-2 hash
 

How to use this tool

  1. Pick a variant with the tabs at the top — SHA-256 (default), SHA-224, SHA-384, or SHA-512.
  2. Type or paste your text into the Input text box. The digest appears instantly in the SHA-2 hash field as you type.
  3. Check Uppercase hex to switch the digest from lowercase to uppercase hex digits.
  4. Hit Copy hash to copy the digest to your clipboard, or Clear to reset the input.
  5. The line under the digest shows its size in bytes and bits — for example 32 bytes (256 bits) for SHA-256.

Why this tool is helpful

Verify downloads & checksums

Download pages publish SHA-256 digests so you can confirm a file wasn't corrupted or tampered with. Hash your copy and compare.

Fingerprint files & dedupe data

A digest is a fixed-size fingerprint of any input. Use it to detect duplicates, build cache keys, or address content deterministically.

Hash secrets & derive keys

SHA-256 and SHA-512 are building blocks for password hashing and key derivation when combined with a salt and many rounds (e.g. PBKDF2).

Understand Git & Bitcoin

Git commit hashes and Bitcoin mining both rely on SHA-256. See the same digest format those systems produce.

Learn the FIPS 180-4 standard

Compare the four SHA-2 variants side by side and see exactly how output size scales from 224 to 512 bits.

Stay private

Everything runs in your browser via the Web Crypto API. Your input is never sent to, stored on, or logged by a server.

FAQ

What is SHA-2?

SHA-2 is a family of cryptographic hash functions standardized in FIPS PUB 180-4. It maps input of any length to a fixed-size digest and includes SHA-224, SHA-256, SHA-384, and SHA-512.

What's the difference between the four variants?

Only the digest size. SHA-224 produces 28 bytes, SHA-256 produces 32, SHA-384 produces 48, and SHA-512 produces 64 bytes (224, 256, 384, and 512 bits). The underlying construction is the same family.

Is hashing the same as encryption?

No. A hash is one-way — you cannot recover the original input from a digest. Encryption is reversible with the right key. This tool only computes one-way digests.

Why is the digest always the same length, even for empty input?

SHA-2 always outputs a fixed number of bytes regardless of input size. An empty string still produces a valid (and well-known) digest for the selected variant.

Is SHA-2 still considered secure?

Yes. There are no practical collision or preimage attacks against SHA-2, unlike the broken MD5 and SHA-1. NIST recommends SHA-256 or stronger for new systems.

What about SHA-512/224 and SHA-512/256?

Those are truncated SHA-512 variants. They aren't exposed here because browser Web Crypto support is not universal yet, so only the four full variants are offered.

Does any of my data leave my browser?

Never. Digests are computed locally with the browser's crypto.subtle.digest Web Crypto API. Your input is not sent to, stored on, or logged by any server.