Hash Generator
SecurityGenerate MD5, SHA-1, SHA-256, SHA-384, and SHA-512 hashes from any text instantly. All hashing runs in your browser — nothing is uploaded or stored.
What is a Hash?
A Hash Generator takes any text input and produces its cryptographic hash — a fixed-length fingerprint computed by a hash algorithm. This tool generates five hashes simultaneously: MD5, SHA-1, SHA-256, SHA-384, and SHA-512. All computation runs in your browser using the built-in Web Crypto API and a pure JavaScript MD5 implementation — nothing is transmitted to any server.
A hash is deterministic and one-way: the same input always produces the same output, but the original input cannot be reconstructed from the hash. A single character change anywhere in the input produces a completely different hash — this property, called the avalanche effect, is what makes hashes useful for integrity verification. The SHA-256 hash of "hello" starts with 2cf24db... and the hash of "Hello" (capital H) is an entirely different 64-character string.
Hash functions are fundamental to modern software: Git uses SHA-1 (transitioning to SHA-256) to identify every commit and file object; Linux package managers publish SHA-256 checksums alongside downloads so users can verify integrity; HTTPS certificate signing uses SHA-256; most API webhook verification systems use HMAC-SHA256 to prove request authenticity. Understanding which algorithm to use and why is one of the foundational skills in backend and security development.
For generating cryptographically random API keys and tokens (rather than hashing known text), use the API Key Generator. For strong passwords, use the Password Generator, which produces random credentials rather than hashes.
How to use this Hash calculator
- Type or paste your text into the Text to Hash field. The hashes update automatically as you type.
- Read the five hash outputs — MD5, SHA-1, SHA-256, SHA-384, and SHA-512 appear simultaneously.
- Copy the hash you need using the copy button next to each output.
- Compare against an expected value — if the hashes match, the input text is identical. If they differ, even by one character, the hashes will be completely different.
Formula & Methodology
SHA-1, SHA-256, SHA-384, SHA-512 are computed using the browser's built-incrypto.subtle.digest()API — the same cryptographic implementation used by the browser for HTTPS. The text is encoded as UTF-8 bytes usingTextEncoder, passed tocrypto.subtle.digest(), and the resultingArrayBufferis converted to a lowercase hex string. MD5 is computed using a pure JavaScript implementation of RFC 1321 — synchronous, no external library, running entirely in the browser. The implementation is a standard LCG-based MD5 using 32-bit integer arithmetic. Important limitations: - MD5 and SHA-1 are cryptographically broken — do not use them for new security applications. Use SHA-256 or higher. - This tool hashes text (UTF-8 encoded). File hashing requires a different approach (reading the file as an ArrayBuffer). - The tool does not perform HMAC — it computes plain hashes only.