ToolDoor
ToolsGuidesPricing
  1. Home
  2. /
  3. Guides
  4. /
  5. Hash Generator

9 min read · updated August 2, 2026

Hash Generator Guide: MD5 vs SHA-256, Explained Properly

Hash Generator

Generate MD5, SHA-256 hashes — free, no signup

A hash generator runs text or a file through a cryptographic hash function — MD5, SHA-1, SHA-256, or SHA-512 — and returns a fixed-length fingerprint of the input. The same input always yields the same digest, any change to the input yields a completely different one, and there is no way to run the function backward. Those three properties make hashes the standard mechanism for verifying that data has not changed in transit or storage.

The tool page tells you which algorithms are available and how to use them. This guide covers what the on-page copy cannot: how a hash function actually digests input block by block, what it means that MD5 and SHA-1 are broken and why that matters for some jobs and not others, the exact procedure for verifying a downloaded file, and the jobs hashes are routinely misused for.

By the end you should be able to pick the right algorithm without guessing and read a checksum mismatch for what it actually tells you.

What a hash actually is

A cryptographic hash maps input of any size to output of one fixed size. MD5 always produces 128 bits, written as 32 hexadecimal characters; SHA-256 produces 256 bits, written as 64 hex characters; SHA-512 produces 512 bits, or 128 hex characters. Hash a five-letter word or a 4 GB disk image and the digest length is identical — the digest is a fingerprint of the content, not a container for it.

Three properties do all the work. Determinism: the same bytes always hash to the same digest, on any machine, forever, which is what makes a published checksum meaningful. The avalanche effect: flipping a single bit of input changes roughly half the output bits, so the MD5 of hello, which is 5d41402abc4b2a76b9719d911017c592, shares no visible resemblance to the MD5 of Hello. Preimage resistance: given a digest, there is no computational path back to the input other than guessing inputs and checking.

Note what is absent from that list: secrecy. A hash involves no key and hides nothing by itself — anyone can hash the same input and get the same result. That is a feature for verification and a trap for anyone who mistakes hashing for encryption, a distinction the last section returns to.

How a hash function digests input, block by block

MD5, SHA-1, and SHA-256 all follow the same construction. The input is first padded to a multiple of the block size — 512 bits for these three, 1024 for SHA-512 — with the padding including the original message length, so that inputs of different lengths can never collapse into identical padded messages. The padded input is then split into blocks and fed one at a time through a compression function.

The compression function is where the mixing happens. It maintains an internal state — 256 bits of it for SHA-256, initialized to fixed published constants — and combines each block into that state through dozens of rounds of bitwise operations: rotations, shifts, XORs, and modular additions, 64 rounds per block in SHA-256. Each round scrambles the state further, and the output state of one block becomes the input state for the next, chaining every block to everything before it. After the final block, the internal state is read out as the digest.

This chaining explains the avalanche effect: a one-bit change in any block alters that block's compression output, which changes the starting state for every subsequent block, compounding through hundreds of rounds until the final digest is unrecognizable. It also explains irreversibility at an intuitive level — each round discards information through many-to-one operations, and with infinitely many possible inputs mapping onto a fixed number of digests, the original input simply is not recoverable from the output. There is nothing to decrypt because nothing was stored.

MD5, SHA-1, SHA-256, SHA-512: what broken means

When cryptographers call MD5 broken, they mean collision resistance has failed: it is cheap to construct two different inputs that produce the same MD5 digest. Practical collisions were demonstrated in 2004 and modern hardware finds them in seconds. SHA-1 followed in 2017, when the SHAttered attack produced two different PDF files with identical SHA-1 digests, and browsers, certificate authorities, and Git have all since moved away from it.

The nuance is which property broke. Collisions require the attacker to craft both inputs; finding a second input matching an existing digest — a preimage attack — remains impractical even for MD5. That is why an MD5 checksum still detects accidental corruption perfectly well: random transmission errors do not conspire to produce colliding files. But in any adversarial setting — signatures, certificates, software distribution where an attacker might substitute a malicious file crafted to match — collision weakness is fatal, and MD5 and SHA-1 are disqualified.

Choosing among the survivors is simple. SHA-256 is the default for integrity verification, signatures, and general use, with no practical attacks against it. SHA-512 offers a larger digest and runs faster than SHA-256 on 64-bit processors for large inputs, since it processes bigger blocks per iteration; it is a fine choice for long-lived archival checksums. Use MD5 only when a legacy system demands it or for casual duplicate detection among files nobody is trying to forge, and treat any security document that specifies MD5 or SHA-1 as a red flag about its age.

Verifying a download checksum, step by step

The canonical scenario: you download a Linux ISO or an installer from a mirror, and the project publishes a SHA-256 checksum on its official site. The point of checking is that the file may have passed through a mirror, a CDN, and a flaky connection the publisher does not control — the checksum ties the bytes you received to the bytes they released.

  • Get the expected digest from the publisher's official site over HTTPS, not from the mirror that served the file — a checksum hosted next to a tampered file would simply be tampered to match.
  • Hash the downloaded file with the same algorithm the publisher used; SHA256SUMS means SHA-256, and hashing with the wrong algorithm guarantees a mismatch.
  • Compare the full digest, not the first few characters; partial matches are how lookalike attacks slip through, and full 64-character comparison costs nothing when pasted into a comparison field.
  • Hex letter case does not matter — ABC123 and abc123 are the same digest — but every character must match.
  • On a mismatch, re-download first: an interrupted transfer is the common cause. If a fresh download from a different mirror still mismatches, do not run the file.
  • For software releases, prefer a signed checksum file or code signature when offered, since a signature proves who published the hash, which the hash alone cannot.

What a hash will not do

A hash does not hide short or guessable content. Because hashing is deterministic and keyless, anyone can hash candidate inputs and compare: the MD5 or SHA-256 of password123, common names, phone numbers, and every string that has ever appeared in a wordlist sits in public lookup tables, which is why pasting a leaked MD5 into a search engine so often returns the original. Hashing an email address or ID number does not anonymize it in any meaningful way if the input space is small enough to enumerate.

A plain hash is also the wrong tool for storing passwords, and this is the most consequential misuse in practice. SHA-256 is designed to be fast, and fast is exactly wrong for password storage: GPU rigs compute billions of SHA-256 hashes per second, so an unsalted fast hash of a human-chosen password falls quickly. Production systems use dedicated password-hashing functions — bcrypt, scrypt, or Argon2 — which add a unique salt per password and deliberately burn time and memory per guess. A hash generator is the right tool for testing and verifying such implementations against known values, not a substitute for them.

Finally, a matching hash proves integrity, not authenticity. It tells you the file matches the published digest; it cannot tell you who published the digest. Pairing a hash with a signature, or at minimum fetching the digest from a source you trust over HTTPS, is what closes that gap.

Common questions

Hash Generator FAQs

Can you decrypt an MD5 or SHA-256 hash back to the original text?
No, hashing is one-way and there is nothing to decrypt, because the function discards information at every round. What attackers actually do is guess: hash billions of candidate inputs and compare against the target, or consult precomputed lookup tables of common strings. That works only when the original input was short or guessable, which is why hashes of common passwords are trivially reversed by lookup while hashes of long random data are not.
Is MD5 still safe to use for anything?
MD5 is safe only for detecting accidental corruption and finding duplicate files in non-adversarial settings. Its collision resistance is fully broken, so it must not be used for digital signatures, certificates, password storage, or verifying software that an attacker could have substituted. When you have a choice of algorithm, use SHA-256.
What is the difference between SHA-256 and SHA-512?
SHA-256 produces a 256-bit digest and SHA-512 a 512-bit digest, and both are considered secure with no practical attacks. SHA-512 processes 1024-bit blocks and typically runs faster on 64-bit CPUs for large files, while SHA-256 is the more widely required by standards, protocols, and published checksum files. Match whatever the system you are interoperating with expects; for a free choice, SHA-256 is the conventional default.
How do I verify the checksum of a downloaded file?
Get the expected digest from the publisher's official page, hash your downloaded copy with the same algorithm, and compare the two strings in full. A match means the file arrived byte-for-byte intact; a mismatch usually means an interrupted download, so fetch it again before assuming tampering. For anything security-sensitive, prefer publishers who sign their checksum files, since the signature proves who issued the hash.
Why am I getting a different hash than the one I expected for the same text?
The inputs are almost certainly not identical bytes. A trailing newline, an invisible space, a different letter case, or a different character encoding all produce a completely different digest because of the avalanche effect. Compare the inputs character by character, watch for whitespace added by copy and paste, and note that only the input is case-sensitive — the hex digest itself matches regardless of letter case.
Is it safe to hash sensitive text in an online tool?
It is safe when the hashing runs client-side in your browser, because the input never leaves your device. Browser crypto APIs compute SHA family digests locally, so a client-side generator transmits nothing to any server. Avoid tools that send input to a backend for hashing, since that puts your data on someone else's machine for no technical reason.

Hashes are fingerprints with precise guarantees: same input, same digest; changed input, unrecognizable digest; no path backward. The judgment calls are all about matching the algorithm to the threat — SHA-256 wherever an adversary is conceivable, MD5 only for accidental-corruption checks, and dedicated slow hashes for passwords — and about remembering that a matching digest proves integrity, never identity.

The Hash Generator on ToolDoor is free, requires no signup, and computes MD5, SHA-1, SHA-256, and SHA-512 digests entirely in your browser, so you can check a download, generate a checksum, or test an implementation without your input ever leaving your machine.

Try Hash Generator now

Free, no signup, no watermarks.

Open the tool

Nearby doors

Password Generator

Generate strong random passwords

Base64 Encoder/Decoder

Encode and decode Base64

URL Shortener

Shorten long URLs with tracking

ToolDoor

Forty-two free online tools for images, PDFs, text, and the odd jobs in between. A SaTekk LLC product.

Tools

  • Image tools
  • PDF tools
  • Text tools
  • SEO tools
  • Utilities

Popular

  • Merge PDF
  • Compress image
  • PDF to Word
  • QR code generator
  • Word counter

Site

  • Guides
  • Pricing
  • Privacy policy
  • Terms of service
  • Cookie policy

Company

  • Contact
  • About SaTekk

© 2026 SaTekk LLC. All rights reserved. · Built by SaTekk ·