Old download pages still print SHA-1 checksums. Newer ones print SHA-256. Both are strings of hex characters produced by the same kind of tool, so it is reasonable to ask what actually changed, and whether the old value on an old page is still worth anything.

The short version: SHA-1 fell because collisions for it have been demonstrated, and SHA-256 took its place because none have ever been found for it in practice. The SHA Hash Generator on Ovatly computes both, plus SHA-384 and SHA-512, in your browser using Web Crypto. This guide explains what a collision means, where each algorithm now stands, and how to tell the two digests apart at a glance.

Contents

  • Quick answer
  • What a collision actually means
  • Where SHA-1 stands now
  • Where SHA-256 stands
  • Telling them apart: 40 characters vs 64
  • How to check an old SHA-1 checksum, step by step
  • Worked example: the abc test value
  • Limitations and honest tradeoffs
  • Common mistakes
  • FAQs
  • Conclusion
  • References

Quick answer

Use SHA-256 for anything new: it is the right default for new checksums and integrity claims. Keep SHA-1 for exactly one job, verifying an old published checksum that was issued as SHA-1. You can tell the two apart by length alone: a SHA-1 digest is 40 hex characters, a SHA-256 digest is 64. The SHA Hash Generator produces either one with the same steps, so an old page's checksum can still be checked even though the algorithm behind it has been retired.

What a collision actually means

A hash algorithm is supposed to give every distinct input its own digest. A collision is the failure of that promise: two different inputs that produce the same digest. If collisions can be constructed, then a file can be swapped for a different file that carries the same checksum, and the check that was meant to catch the swap passes instead.

That is why demonstrated collisions end an algorithm's career in integrity work. The problem is not that every existing checksum suddenly becomes wrong. Your old file still hashes to its old value. The problem is trust going forward: a fresh SHA-1 checksum can no longer rule out a deliberately crafted substitute, so it cannot support a new integrity claim.

Where SHA-1 stands now

SHA-1 is a legacy algorithm. Collisions for it have been demonstrated, which moves the weakness from theory into practice. It is not used for new integrity claims, and a publisher issuing a new release today should not offer SHA-1 as the checksum of record.

What survives is a narrow, honest use. Old releases were published with SHA-1 checksums, and those values are still the reference for those files. Reproducing a SHA-1 digest to compare against a checksum printed years ago is legitimate verification of history. The tool keeps SHA-1 available for precisely that job, labelled by its place in the list rather than presented as an equal choice.

Where SHA-256 stands

SHA-256 is the current default. No collision for it has ever been found in practice, and that clean record is why publishers, standards and checksum files settled on it as the replacement. When you generate a checksum for a file you are publishing, or a download page offers one value with no label, SHA-256 is the algorithm to reach for and the one to assume.

It is also the sensible middle of the family the tool offers. SHA-384 is common in some standards, and SHA-512 is fine on 64-bit systems, but neither needs to displace SHA-256 for ordinary file verification. Pick the longer variants when a standard or a publisher's checksum file calls for them, and SHA-256 the rest of the time.

Telling them apart: 40 characters vs 64

The fastest field test needs no tool at all: count the characters. A SHA-1 digest is 40 hex characters long. A SHA-256 digest is 64. Download pages usually label the algorithm next to the value, but labels get lost when checksums are copied into forum posts, release notes and emails, and the length tells you what you are holding.

Length also protects you from a wasted comparison. A SHA-1 digest of a file will never equal a SHA-256 digest of the same file, so if your computed value is 40 characters and the reference is 64, the mismatch is explained before you suspect the file. Select the algorithm that matches the reference, then compare.

How to check an old SHA-1 checksum, step by step

  1. Open the SHA Hash Generator and select SHA-1, matching the algorithm the old page used.
  2. Choose File and select the downloaded file. It is read locally in your browser and never leaves your device.
  3. Click Compute and copy the hex digest.
  4. Compare it with the published value character by character. A full match means your bytes are identical to the bytes that checksum was taken from.

Worked example: the abc test value

To see the modern default in action, type the three letters abc as text, select SHA-256, and compute. The digest is the worked example published in FIPS 180-4:

ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad

Count the characters and you get 64, the SHA-256 length. Run the same three letters with SHA-1 selected instead and the output is a visibly shorter string of 40 characters. Same input, same workflow, two different algorithms, and the length alone tells you which is which. That small check, counting before comparing, prevents the most pointless mismatch in checksum work: comparing values from two different algorithms and concluding the file is corrupt.

Limitations and honest tradeoffs

A hash, from either algorithm, proves that bytes match a reference. It does not prove who published the file. A SHA-256 match against a checksum copied from an untrusted page proves only that you have the file that page described.

Text input carries a practical trap: text is hashed as UTF-8 exactly as entered, and a trailing newline counts, which is the most common reason a result disagrees with an expected value. Files avoid that trap, but very large files are read fully into memory, so an enormous file can be slow to hash on a modest device. Finally, verifying an old SHA-1 checksum tells you the file matches its historical record; it cannot upgrade that record into a modern integrity guarantee.

Common mistakes

  • Issuing new checksums as SHA-1. Collisions have been demonstrated. New integrity claims belong on SHA-256.
  • Comparing digests from different algorithms. A 40 character SHA-1 value and a 64 character SHA-256 value for the same file will never match. Align the algorithm first.
  • Assuming an old SHA-1 checksum is worthless. It still verifies the file it was published with. Its weakness is about new claims, not historical ones.
  • Blaming the file for a text mismatch. A trailing newline in pasted text changes the digest completely. Check the input before suspecting corruption.
  • Trusting a checksum because it matches. The reference has to come from a trusted source; the hash only ties your bytes to that reference.

FAQs

Is SHA-1 still safe to use? Not for new integrity claims. Collisions for SHA-1 have been demonstrated, meaning two different inputs can be made to produce the same digest. SHA-1 remains acceptable for one narrow job: verifying an old published checksum that was issued as SHA-1, where you are matching a historical value rather than making a new claim.

Has SHA-256 ever been broken? No collision for SHA-256 has ever been found in practice. That record is the main reason it is the default algorithm for new checksums and integrity checks.

How can I tell a SHA-1 and a SHA-256 checksum apart? Count the characters. A SHA-1 digest is 40 hex characters long and a SHA-256 digest is 64. Download pages usually label the algorithm, but the length confirms it when the label is missing or unclear.

Why do some download pages still show SHA-1 checksums? Because those checksums were published when SHA-1 was still the common choice, and old releases keep their original checksums. Verifying one of those values is a fair use of SHA-1. Publishing a new release with only a SHA-1 checksum is not.

Can one tool produce both SHA-1 and SHA-256? Yes. The SHA Hash Generator computes SHA-1, SHA-256, SHA-384 and SHA-512 in your browser using Web Crypto, so you can reproduce an old SHA-1 checksum or generate a new SHA-256 one with the same workflow.

Conclusion

Sites moved on because the evidence moved: SHA-1 collisions stopped being theoretical, and SHA-256 kept its clean record. The practical rule is simple. SHA-256 for anything new, SHA-1 only to check the old values that history left behind, and a quick character count, 40 against 64, whenever a checksum arrives without a label. The SHA Hash Generator covers both algorithms in one place, running entirely in your browser. For the full walkthrough of generating each member of the family, see our guide on how to generate SHA-1, SHA-256 and SHA-512 hashes. For more guides in this series, see our Security and Privacy guides.

References