A hash function takes an input of any size and produces a fixed-length output — a "fingerprint" of the data. The same input always produces the same output, but you cannot reverse the process to recover the input from the hash. This one-way property is what makes hashing useful for security.
What hashing is used for
- Password storage — applications store a hash of your password, not the password itself. When you log in, the input is hashed and compared to the stored hash.
- File integrity verification — software downloads often include an SHA-256 checksum so you can verify the file was not corrupted or tampered with.
- Digital signatures — the document is hashed; the hash is signed. This is faster than signing the entire document.
- Data deduplication — hash files to find duplicates without comparing bytes.
Common hash algorithms
MD5
Produces a 128-bit (32 hex character) hash. It is fast and still used for file checksums and non-security purposes. Do not use MD5 for passwords — it has known collision vulnerabilities (two different inputs producing the same hash) and is too fast for brute-force resistance.
SHA-1
Produces a 160-bit (40 hex character) hash. Deprecated for security purposes — collision attacks have been demonstrated. Still seen in legacy systems but avoid for new code.
SHA-256
Part of the SHA-2 family. Produces a 256-bit (64 hex character) hash. This is the current standard for security-critical applications. Used in SSL/TLS certificates, Bitcoin, and most modern authentication systems.
SHA-512
Produces a 512-bit (128 hex character) hash. Slightly stronger than SHA-256 and actually faster on 64-bit processors, but SHA-256 is sufficient for almost all use cases.
Generate a hash
The Hash Generator computes MD5, SHA-1, SHA-256, and SHA-512 from any text input — directly in your browser, without sending the text anywhere.
- Open the Hash Generator.
- Type or paste your input.
- The hashes for all four algorithms appear instantly.
Hashing vs encryption
These are often confused:
- Hashing is one-way. You cannot recover the original input. Used for verification.
- Encryption is two-way. The ciphertext can be decrypted with the right key. Used for confidentiality.
Never encrypt passwords — hash them (ideally with a slow, salted algorithm like bcrypt or Argon2 in production code). For simple text hashing and checksum generation, SHA-256 via the Hash Generator is the right choice.
Checking a file download
When a site provides an SHA-256 checksum for a download, hash the file you received and compare. If the hashes match, the file is intact. If they differ, the download was corrupted or the file was modified.
Explore 285+ free tools
No signup, no watermarks — everything runs privately in your browser.
Browse all tools