Hash Generator
Interactive StudioGenerate SHA-1, SHA-256, SHA-384, and SHA-512 hashes of your text using the Web Crypto API. Instant feedback with zero server storage.
Loading tool…
About Hash Generator
A cryptographic hash function takes any input text and produces a fixed-length string of hex characters — the digest — such that even a one-character change in the input produces a completely different digest. This tool runs your text through the browser's native Web Crypto API to compute SHA-1, SHA-256, SHA-384, and SHA-512 digests side by side, entirely on-device, with nothing sent over the network.
Hashing is one-way and deterministic, not encryption: there's no key involved, and there's no way to recover the original text from the digest, unlike encryption which is designed to be reversed with the right key. SHA-1 is included for compatibility with older systems but is considered cryptographically weak — collisions have been demonstrated in practice — so SHA-256 or a longer variant is the safer default for anything security-sensitive. MD5 isn't offered here at all: it's not exposed by the Web Crypto API and is broken badly enough that it shouldn't be used for integrity checks anymore.
Common uses include verifying a downloaded file matches its published checksum, generating a stable fingerprint for caching or deduplication, or comparing two pieces of text for exact equality without storing the text itself — hashes of passwords for real authentication systems should use a dedicated password-hashing algorithm (like bcrypt or Argon2) rather than a raw SHA hash.
How to use Hash Generator
- Type or paste the text to hash.
- SHA-1, SHA-256, SHA-384 and SHA-512 digests are computed side by side.
- Copy the digest you need.
Worked examples
Input: hello
Result: SHA-256: 2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824
Input: hello
Result: SHA-1: aaf4c61ddcc5e8a2dabede0f3b482cd9aea9434d
Input: Hello (capital H)
Result: SHA-256 begins 185f8db32271fe25, completely different from the digest for hello.
Background
A hash function maps input of any size to a fixed-length digest. It is deterministic and one-way, and a tiny input change produces an unrelated output. SHA-256 gives 256 bits, shown as 64 hex characters.
SHA-1 is broken for collision resistance and should not be used for security. SHA-256 and above are fine for checksums and integrity. For storing passwords, use a slow, salted algorithm such as bcrypt, scrypt or Argon2 rather than a plain SHA hash. Digests are computed by the browser's Web Crypto API on your device.
Common mistakes
- Hashing passwords with plain SHA-256, which is too fast to resist brute force.
- Comparing hashes of text that differ by a trailing newline or whitespace.
- Treating a hash as encryption. It cannot be reversed or decrypted.
Frequently Asked Questions
Frequently Paired With
Fast, local-first developer micro-tools with zero tracking or latency.
UUID Generator
Generate random UUIDs (v4).
Cron Expression Generator
Build and describe cron expressions.
JWT Decoder
Decode a JWT's header and payload.
Regex Tester
Test regular expressions with live highlighting, group captures & replacement.
