Compute SHA-1 digests

Compute a legacy SHA-1 digest for compatibility or file fingerprinting.

freeworks offlinenothing uploaded
ToolSHA-1 Hash
Input
Output
Put this on your own site

The frame below runs the same code as this page, in the reader's own browser. Nothing is sent to us, and nothing is sent to you.

Pick a dark background and the text and panels follow it, so the frame stays readable on a dark page.

Preview

How it works

Bytes are padded with a length field and processed in 512-bit blocks through 80 rounds, producing five 32-bit words and a 160-bit digest. The result is deterministic but not suitable for new collision-sensitive security uses.

  • SHA-1 remains for legacy interoperability.
  • Collision attacks limit new security use.

Worked example

Simple Hash
Generate the SHA-1 digest of a short string
Input
											hello
										
Output
												aaf4c61ddcc5e8a2dabede0f3b482cd9aea9434d
											

When to use this

Legacy Git objects, compatibility checksums, and digest migrations use SHA-1.

Edge cases

  • Crafted files can share a collision.
  • One byte changes the digest unpredictably.
  • A hash does not hide or recover input.

References