Hash Generator
Generate cryptographic hashes (MD5, SHA-1, SHA-256, SHA-512, SHA3-256, SHA3-512) from any text. Processing done server-side with PHP.
Frequently Asked Questions
apt, npm, and pip verify package hashes before installation; and Git uses SHA-1 (moving to SHA-256) to identify every commit, tree, and blob. To verify a file manually: sha256sum downloaded-file.iso on Linux/macOS, or Get-FileHash downloaded-file.iso -Algorithm SHA256 in PowerShell, then compare the output to the published checksum.HMAC(key, message) = H((key XOR opad) || H((key XOR ipad) || message)). HMACs are used to verify both the integrity (data not altered) and authenticity (came from a party with the key) of a message. They are used in JWTs (to sign the token), API authentication (AWS Signature, Stripe webhooks), and cookie signing. Use HMAC-SHA256 as the standard — avoid HMAC-MD5 and HMAC-SHA1 for new designs.About This Hash Generator
This free hash generator computes cryptographic hashes for any text input using MD5, SHA-1, SHA-256, SHA-384, and SHA-512 algorithms. Enter text and instantly see the hash output for every algorithm side by side.
Hash functions are one-way: they produce a fixed-length fingerprint of any input, and it is computationally infeasible to reverse them. They are used for data integrity verification, checksums, digital signatures, and (for bcrypt/Argon2) password storage.
When to use this tool
- Generating SHA-256 checksums to verify file integrity
- Comparing hash outputs across different algorithms
- Testing hash behaviour for edge cases like empty strings
- Learning the difference between MD5, SHA-1, and SHA-256
Standards & References
How Hash Generation Works
A cryptographic hash function maps any input to a fixed-length fingerprint deterministically and irreversibly.
Send to PHP Backend
The input text is sent to the PHP API endpoint via a GET request. PHP processes it server-side using the native hash() function, which wraps the system's cryptographic library.
Apply Algorithm
PHP's hash('sha256', $input) feeds the input bytes through the selected algorithm's compression function (MD5: 128-bit, SHA-1: 160-bit, SHA-256: 256-bit, SHA-512: 512-bit output).
Return Hex Digest
The raw binary output is hex-encoded to produce a human-readable string. The "Hash All" option runs all six algorithms in one request and returns them together for easy comparison.
Common Use Cases
File Integrity Verification
Software downloads publish SHA-256 checksums so users can verify the downloaded file hasn't been tampered with. Hash the file content and compare against the published digest — any difference means corruption or alteration.
Cache Key Generation
Hashing a query, template, or response body produces a short deterministic cache key. SHA-256 is compact (64 hex chars) and collision-resistant, making it ideal for cache tags in Redis, Memcached, and CDN configs.
Content Deduplication
Hash-based deduplication stores only one copy of each unique piece of content and uses the hash as the key. File storage systems (Git, content-addressed stores) use SHA-1/SHA-256 for this purpose.
Data Fingerprinting
Hash API request bodies, config versions, or schema snapshots to detect changes without storing the full content. Compare the current hash against a stored hash to detect drift in data pipelines or deployments.
HMAC & Digital Signatures
HMAC (Hash-based Message Authentication Code) uses a hash function (SHA-256 or SHA-512) combined with a secret key. Understanding the underlying hash algorithm helps when implementing or debugging webhook signature verification.
Algorithm Comparison
Use "Hash All" to compare output lengths and performance characteristics of all six algorithms at once. This helps when selecting the right algorithm for a new system — balancing speed, digest length, and collision resistance.
Related Developer Tools
Related Articles
View all articles
What Developers Still Get Wrong About Password Storage in 2024
LinkedIn stored 117 million passwords as unsalted SHA-1 — cracked within days. Adobe used 3DES encryption (reversible) instead of hashing. These are the specific, named password storage mistakes that keep producing data breaches. Here's every common error, why it fails, and the correct modern approach with bcrypt and Argon2.
How File Hash Verification Actually Works: Determinism, the Avalanche Effect, and What "Match" Really Means
Hashing the same file twice, a year apart, on different computers, produces the exact same hash — this single property, determinism, is the foundation of file-integrity verification. Here's how the avalanche effect guarantees "match or no match, with no partial credit," why fixed output size makes hash comparison practical for huge files, the proper download-verification workflow, and why where a published hash comes from matters as much as the comparison itself.
Merkle Trees and Hash Functions: How Git, Blockchain, and Certificate Transparency Work
Hash functions underpin Git commits, blockchain blocks, and certificate transparency logs through Merkle trees. Here's why MD5 and SHA-1 are "broken," how Merkle trees verify large datasets with O(log n) hashes, and how Bitcoin light clients verify transactions without the full blockchain.
Hash Generator — MD5, SHA-256, SHA-512 & SHA-3 for Data Integrity
Learn how cryptographic hash functions work, when to use MD5 vs SHA-256 vs SHA-3, the avalanche effect, why hashes can't be used for passwords, and how to use a free hash generator for integrity verification.
Hash Generator — MD5, SHA-1, SHA-256 & SHA-512 Explained
Learn how hash functions work, the differences between MD5, SHA-1, SHA-256, and SHA-3, which algorithm to use for file verification vs. passwords, and how to generate hashes instantly with a free tool.