Hash Generator

Hash text or a file with five common algorithms at once and check a download against a published checksum.

🔒 Runs entirely in your browser. Nothing you enter is sent to a server.

A hash function turns any input, from a single word to a multi-gigabyte file, into a short fixed-length fingerprint. Change a single character and the fingerprint changes completely. This hash generator calculates the five most common fingerprints at once, for text or for files, and can check a result against a checksum you already have.

How to use the hash generator

  1. Type or paste text into the box. Hashes update as you type.
  2. Or click Hash a file instead and choose a file from your device.
  3. Tick Uppercase if the system you are comparing with uses capital letters.
  4. To verify a download, paste the published checksum into the Compare box. The tool tells you which algorithm matches, if any.

Text is encoded as UTF-8 before hashing, which is the standard used by almost every programming language and command-line tool.

How hashing works

Every algorithm here follows the same idea:

  1. The input is split into fixed-size blocks, 512 bits for MD5, SHA-1 and SHA-256, and 1024 bits for SHA-384 and SHA-512.
  2. The last block is padded, and the length of the message is added at the end.
  3. Each block is mixed into an internal state through many rounds of bit rotations, additions and logical operations.
  4. The final state is written out as hexadecimal digits.
Algorithm Output size Hex length Security status
MD5 128 bits 32 Broken, use for corruption checks only
SHA-1 160 bits 40 Broken, avoid for new security uses
SHA-256 256 bits 64 Secure, the usual default
SHA-384 384 bits 96 Secure
SHA-512 512 bits 128 Secure

Worked example

Hashing the text Hello, world! (13 bytes in UTF-8) gives:

  • MD5: 6cd3556deb0da54bca060b4c39479839
  • SHA-1: 943a702d06f34599aee1f8da8ef9f7296031d699
  • SHA-256: 315f5bdb76d078c43b8ac0064e4a0164612b1fce77c869345bfc94c75894edd3

Now remove the exclamation mark. Every hash changes beyond recognition. This is called the avalanche effect, and it is what makes hashes useful as fingerprints: there is no way to tell from two hashes how similar the inputs were.

Common uses for hashes

  • Verifying downloads. Software publishers list a SHA-256 checksum next to their files. Hash your copy and compare. A match means the file was not corrupted or tampered with on the way.
  • Detecting duplicates. Two files with the same SHA-256 hash are, for all practical purposes, identical.
  • Caching and versioning. Build tools put a short hash of a file’s contents in its name, so browsers download it again only when it changes.
  • Data integrity. Databases and backup systems store hashes to spot silent corruption.
  • Digital signatures. Signatures are made over the hash of a document rather than the whole document.

Checking a hash on your computer

You can produce the same results from the command line:

Windows PowerShell:  Get-FileHash file.zip -Algorithm SHA256
macOS:               shasum -a 256 file.zip
Linux:               sha256sum file.zip

Tips and pitfalls

  • Watch for hidden characters. echo text | sha256sum hashes the text plus a newline, so it will not match this tool. Use echo -n or printf instead.
  • Hex case does not matter. ABC123 and abc123 are the same hash written differently.
  • Hashes are not encryption. A hash cannot be decrypted. If you need to get the data back, you need encryption, not hashing.
  • Use HMAC for message authentication. A plain hash of a secret plus a message is open to length-extension attacks with SHA-256. HMAC-SHA256 is the safe construction.

Frequently asked questions

Can a hash be reversed to get the original text?

No. Hash functions are one-way. The only way to find the input is to guess it and compare hashes, which is why short or common inputs, such as simple passwords, can be found in precomputed tables while long random inputs cannot.

Which hash algorithm should I use?

Use SHA-256 for most purposes, including checksums and digital fingerprints. MD5 and SHA-1 are broken for security use because collisions can be created on purpose, but they are still fine for spotting accidental corruption.

Should I use SHA-256 to store passwords?

No. General-purpose hashes are designed to be fast, which makes guessing attacks fast too. Store passwords with a slow, salted password hashing function such as Argon2id, bcrypt or scrypt.

Why does my hash differ from another tool's?

Usually the input differs by something invisible, such as a trailing newline, a space, Windows line endings or a different text encoding. This tool hashes exactly what is in the box, encoded as UTF-8.

Is my file uploaded when I hash it?

No. The file is read and hashed by your browser on your own device. Nothing is sent to a server, so you can safely hash private files.

Last updated October 28, 2026 · By the ZTool team