Hash Generator
Generate MD5, SHA-1, SHA-256, SHA-384, and SHA-512 hashes from text or files. All processing happens 100% in your browser — no data is ever sent to a server.
Hash Text
Enter or paste any text below. Hashes are computed instantly using the Web Crypto API (SHA variants) and a pure JavaScript implementation (MD5).
Hash File
Drag and drop a file or click to select one. The file is read entirely in your browser — nothing is uploaded. Supports any file type and size.
What Is a Cryptographic Hash Function?
A cryptographic hash function is a mathematical algorithm that takes an input (or "message") of any length and produces a fixed-size string of bytes, called a digest or hash value. The output is deterministic — the same input always produces the same hash — but even a tiny change in the input produces a completely different output. This property is known as the avalanche effect.
Cryptographic hashes are one-way functions: it is computationally infeasible to reverse-engineer the original input from its hash. This makes them essential for password storage, data integrity verification, digital signatures, and blockchain technology.
Supported Hash Algorithms
MD5 (128-bit)
Produces a 32-character hex digest. Fast but cryptographically broken — vulnerable to collision attacks. Use only for checksums and non-security purposes like file deduplication.
SHA-1 (160-bit)
Produces a 40-character hex digest. Deprecated for security use since 2017 after practical collision attacks (SHAttered). Still found in legacy systems and Git commit hashes.
SHA-256 (256-bit)
Part of the SHA-2 family. Produces a 64-character hex digest. Widely used in TLS certificates, Bitcoin, code signing, and data integrity. The current industry standard.
SHA-384 (384-bit)
A truncated version of SHA-512. Produces a 96-character hex digest. Used in government and financial systems requiring higher security margins.
SHA-512 (512-bit)
The strongest SHA-2 variant. Produces a 128-character hex digest. Preferred on 64-bit systems where it can be faster than SHA-256. Used in high-security applications.
Common Use Cases for Hash Functions
- Password Storage: Passwords are hashed (with salt) before storage so the original password is never kept in plaintext.
- File Integrity: Compare the hash of a downloaded file against the published hash to verify it has not been tampered with or corrupted.
- Digital Signatures: Documents are hashed before signing to ensure the signature covers the exact content.
- Blockchain: SHA-256 is the foundation of Bitcoin's proof-of-work consensus and Merkle tree structure.
- Deduplication: Identical files produce identical hashes, enabling efficient storage and content-addressable systems like Git.
- Data Integrity in APIs: HMAC (Hash-based Message Authentication Code) uses hash functions to verify API request authenticity.
Why Client-Side Hashing Matters
This tool computes all hashes entirely in your browser using the Web Crypto API for SHA variants and a pure JavaScript implementation for MD5. Your input text and files never leave your device. There is no server-side processing, no logging, and no tracking — your data remains completely private.