Generate secure cryptographic hashes for text and files using multiple industry-standard algorithms. Everything runs locally in your browser.
Text
43 chars
SHA-256
SHA-256
256 bits64 chars
—
Case and surrounding whitespace are ignored, and a line copied straight from shasum works — the filename after the hash is dropped.
Enter text or choose a file first, then paste a checksum here to compare it.
MD5 and SHA-1 are kept for compatibility and corruption checks only. Both have practical collision attacks, so neither proves a file was not tampered with — use SHA-256, SHA-512 or SHA-3. And never store passwords with any hash on this page: they are built to be fast, which is exactly wrong for a password. Use bcrypt, Argon2 or PBKDF2.
In: 43 characters · 9 words · 1 lines · 0 B
Out: SHA-256 · 64 characters
Hashed in your browser — nothing is uploaded.
Everything happens locally in your browser. Your files and text are never uploaded.
What is a cryptographic hash?
A cryptographic hash is a fixed-size fingerprint of data. Feed a hash function anything — three letters or a three-gigabyte disk image — and it returns the same number of bytes every time. SHA-256 always returns 32 bytes, written as 64 hexadecimal characters.
Four properties make such a function cryptographic rather than merely a checksum:
Deterministic. The same input always produces the same digest, on any machine, in any language, forever. Without this nothing else works.
One-way. Given a digest, there is no way to compute the input. Most of the information was discarded — 32 bytes cannot hold a gigabyte.
Avalanche. Changing one bit of input flips about half the output bits, so similar inputs give unrelated digests.
Collision resistant. Two inputs sharing a digest must exist — infinitely many inputs, finitely many digests — but nobody should be able to find a pair.
That last one is where MD5 and SHA-1 failed. Neither became reversible; both became collidable, which is enough to make them useless for proving that two things are the same.
How hashing works
Nearly every hash here works the same way at a high level. The input is padded to a whole number of blocks, and the blocks are absorbed one at a time into a small internal state. Each block is mixed into the state through many rounds of rotations, additions and exclusive-ors. When the input runs out, the state — or part of it — is the digest.
1input ──▶ pad to block size ──▶ ┌──────────────┐2 │ compress ×N │◀── one block at a time3 └──────┬───────┘4 ▼5 internal state ──▶ digest
Two consequences follow directly from that shape, and both matter in practice.
Hashing can stream. Because blocks are absorbed one at a time, nothing ever needs the whole input in memory. That is why this tool can hash a file larger than your available RAM, and why it can show progress while it does.
The length is fixed by the state, not the input. The digest is a snapshot of a fixed-size state, which is exactly why the output size never varies and why the original cannot be recovered.
The avalanche effect is easiest to see rather than describe. One letter changes, and nothing survives:
One letter apart
1…over the lazy dog → d7a8fbb307d7809469ca9abcb0082e4f8d5651e46d3cdb762d02d0bf37c9e5922…over the lazy cog → e4c4d8f3bf76b692de791a173e05321150f7a345b46484fe427f6acc7ecc81be
SHA-3 is the exception to the picture above. Instead of a compression function it uses a sponge: input is absorbed into a much larger state, then output is squeezed back out. The practical difference is that a sponge does not leak its internal state in the digest, which is why SHA-3 has no length-extension weakness — see the best practices below.
Supported hash algorithms
Thirteen algorithms, grouped by family. Each entry says what it is for and, where relevant, why you should not choose it.
MD5
128 bits · 32 hex · RFC 1321Broken
Collisions were demonstrated in 2004 and can now be produced on a laptop in seconds. Worse, chosen-prefix collisions are practical, which means an attacker can craft two meaningful files — a safe installer and a malicious one — with the same MD5. It survives only because so many projects still publish MD5 checksums, and comparing one tells you a download was not corrupted in transit. It tells you nothing about whether it was tampered with.
SHA-1
160 bits · 40 hex · FIPS 180-4Broken
Google and CWI produced two different PDFs with the same SHA-1 in 2017, and by 2020 chosen-prefix collisions cost roughly $45,000 of compute — cheap enough to matter. Browsers stopped trusting SHA-1 certificates years ago. Git still uses it to name objects, which is a lookup rather than a security boundary, and even Git has been migrating. Do not choose it for anything new.
SHA-224
224 bits · 56 hex · FIPS 180-4Sound
Structurally SHA-256 with different initial values and its output cut short. That truncation is not merely cosmetic: it makes SHA-224 immune to the length-extension attack that affects SHA-256, because an attacker cannot recover the full internal state from the digest. Its 112-bit collision resistance is sound but offers no margin over SHA-256, so there is rarely a reason to prefer it unless something downstream demands 28 bytes.
SHA-256
256 bits · 64 hex · FIPS 180-4Sound
The most widely deployed hash in the world: TLS certificates, Bitcoin, package managers, container digests and code signing all rest on it. No collision or preimage attack comes close to threatening it, and it has held up under twenty years of scrutiny. Its one sharp edge is length extension — given the hash of a secret and a message, an attacker can compute the hash of that message plus a suffix without knowing the secret. That is why authentication uses HMAC-SHA-256 rather than SHA-256 of a secret joined to a message.
SHA-384
384 bits · 96 hex · FIPS 180-4Sound
Built on the 64-bit SHA-512 core and truncated, which — as with SHA-224 — closes the length-extension hole its parent has. It appears throughout TLS 1.2 and 1.3 cipher suites and is a common choice for subresource integrity attributes. On 64-bit hardware it outruns SHA-256; in JavaScript it does not, because the language has no native 64-bit integers.
SHA-512
512 bits · 128 hex · FIPS 180-4Sound
Uses 64-bit words and a longer schedule than SHA-256, giving 256-bit collision resistance — margin far beyond any practical threat, including from quantum search, which halves preimage strength but leaves 256 bits of it. On native 64-bit hardware it is typically faster than SHA-256; in a browser it is about half the speed, because every 64-bit operation has to be emulated with pairs of 32-bit ones.
SHA3-224
224 bits · 56 hex · FIPS 202Modern
SHA-3 was standardised in 2015 not because SHA-2 was failing but because it was prudent to have a successor built on unrelated mathematics. Where SHA-2 uses a Merkle–Damgård construction, SHA-3 uses a sponge, which is why it has no length-extension weakness at any output size.
SHA3-256
256 bits · 64 hex · FIPS 202Modern
The most-used SHA-3 size, and the natural choice when you want SHA-256's strength from a design that shares none of its internals. Note that Ethereum uses original Keccak-256 rather than the standardised SHA3-256 — the two differ in one padding byte and produce entirely different digests, which catches people out constantly.
SHA3-384
384 bits · 96 hex · FIPS 202Modern
A sponge trades speed for capacity: the wider the digest, the less of each block is absorbed per permutation, so larger SHA-3 sizes are meaningfully slower rather than marginally so. That cost buys 192-bit collision resistance on a construction with no known structural weakness.
SHA3-512
512 bits · 128 hex · FIPS 202Modern
Absorbs only 72 bytes per permutation against SHA3-256's 136, so it does roughly twice the work per byte — the slowest of the thirteen in this tool. Choose it when the margin genuinely matters and throughput does not.
BLAKE2b
512 bits · 128 hex · RFC 7693Modern
A SHA-3 finalist that lost the competition and won the deployment. On native 64-bit hardware it is typically faster than MD5 while being as sound as SHA-3, which is why Argon2 uses it internally and why content-addressed stores favour it. In a browser that advantage disappears — its 64-bit rotations have to be emulated, so it lands mid-table here. Output size is adjustable from 1 to 64 bytes; this tool uses the full 64.
BLAKE2s
256 bits · 64 hex · RFC 7693Modern
Same design, narrower words, aimed at 8- to 32-bit platforms where BLAKE2b's 64-bit arithmetic is expensive. Output is adjustable from 1 to 32 bytes; this tool uses the full 32. On modern desktop hardware there is no reason to prefer it over BLAKE2b, but it is the right choice on a microcontroller.
RIPEMD-160
160 bits · 40 hex · ISO/IEC 10118-3Weakened
Designed in Europe as an open alternative to the NSA-designed SHA family, and never broken in the way MD5 and SHA-1 were. Its problem is size: 160 bits gives 80-bit collision resistance, which is uncomfortably close to reachable and is why SHA-1 fell. It persists almost entirely because Bitcoin addresses are RIPEMD-160 of SHA-256 of a public key, so every Bitcoin tool needs it.
Hash algorithm comparison
Security is a judgement about known attacks. Speed is not a judgement at all — it is measured, in this JavaScript implementation, on a 16 MB buffer. That distinction matters: MD5 has a reputation for being fast, and in C it is, but here it is slower than SHA-256.
Algorithm
Bits
Hex
Security
Speed
Collisions
Recommended
MD5
128
32
★☆☆☆☆
★★★☆☆62 MB/s
Broken — collisions in seconds
Legacy checksums only
SHA-1
160
40
★★☆☆☆
★★★★★227 MB/s
Broken — collisions demonstrated
Legacy compatibility only
SHA-224
224
56
★★★★☆
★★★★★165 MB/s
112-bit
Constrained output size
SHA-256
256
64
★★★★★
★★★★★164 MB/s
128-bit
Default choice
SHA-384
384
96
★★★★★
★★★★☆78 MB/s
192-bit
High security
SHA-512
512
128
★★★★★
★★★★☆79 MB/s
256-bit
Maximum SHA-2 margin
SHA3-224
224
56
★★★★★
★★☆☆☆37 MB/s
112-bit
Modern, different foundation
SHA3-256
256
64
★★★★★
★★☆☆☆35 MB/s
128-bit
Modern default
SHA3-384
384
96
★★★★★
★★☆☆☆27 MB/s
192-bit
Modern, high security
SHA3-512
512
128
★★★★★
★☆☆☆☆19 MB/s
256-bit
Maximum modern margin
BLAKE2b
512
128
★★★★★
★★★☆☆45 MB/s
256-bit
Fast on 64-bit hardware
BLAKE2s
256
64
★★★★★
★★★☆☆42 MB/s
128-bit
Constrained platforms
RIPEMD-160
160
40
★★★☆☆
★★★★★174 MB/s
80-bit
Bitcoin compatibility
Two patterns are worth reading out of that table. The SHA-3 family is uniformly the slowest, because a sponge absorbs less of each block as the digest grows wider — SHA3-512 takes in 72 bytes per permutation where SHA3-256 takes 136. And the 64-bit designs — SHA-384, SHA-512, BLAKE2b — all sit below their 32-bit siblings, because JavaScript has no 64-bit integer type and every operation becomes two.
Hashing vs encryption
They are not variants of one idea. They have opposite goals, and confusing them is behind a good share of security incidents.
Encryption is reversible by design. The entire point is that the holder of the key gets the original back. Confidentiality is the goal.
Hashing discards information. There is no key, and no amount of computation recovers the input, because the input is no longer there. Integrity is the goal.
Encryption preserves size; hashing fixes it. Ciphertext grows with the plaintext. A digest never changes length.
So “decrypt this hash” is not a hard problem — it is not a problem at all. What the person usually means is guessing: hash a list of likely inputs and see if any match. That works when the input space is small, which is why it works on passwords and not on files — and why the password generator reports entropy and an estimated crack time, which is a measure of exactly how large that space is.
A third idea sits between them and is often the one actually wanted: message authentication. HMAC combines a hash with a secret key so that a recipient can verify both that data is unaltered and that it came from someone holding the key. Integrity plus authenticity, which a bare hash cannot provide — it is what signs an HS256 token in the JWT generator.
File integrity verification
This is what hashes are for, and the workflow is worth stating precisely because the common version of it is subtly useless.
1. The publisher hashes the file and publishes the digest alongside the download.
2. You hash the file you received — drop it onto this page, which reads it locally and never uploads it.
3. Compare. Identical digests mean identical bytes. Paste theirs into the Verify panel and it marks any character that differs.
The same check from a terminal
1$ shasum -a 256 ubuntu.iso22ac1bd0d84cf1a2f27a2b4a2ee3a3c2d… ubuntu.iso34# paste that whole line into the Verify panel —5# the filename after the hash is ignored
Two things this proves, and one it does not:
It proves the download is not corrupt. A truncated transfer or a failing disk changes the digest completely.
It proves the bytes match what the publisher hashed — provided the algorithm is not MD5 or SHA-1, where an attacker could construct a different file with the same digest.
It does not prove the file is genuine.If the checksum came from the same page as the download, whoever could replace one could replace the other. The checksum has to come from somewhere the attacker does not control — a signed release file, a different domain, a package manager’s own database. This is the step most people skip.
Which is why serious distributions sign their checksum file with a GPG key rather than merely publishing it. The signature establishes who wrote the checksums; the checksums establish what the files are.
Common use cases
Hashing turns “is this the same data?” into a comparison of 32 bytes, which is why it appears almost everywhere data moves or is stored.
File verification
The original use. Hash a download, compare it against the checksum the publisher listed, and you know whether you received the bytes they sent — provided the checksum came from somewhere the attacker could not also edit.
Checksums
Detecting accidental corruption from a bad disk, a truncated transfer or a flaky network. This is the one job MD5 is still adequate for, because random corruption does not conspire to produce a collision.
API signatures
Request signing schemes such as AWS Signature v4 are built on HMAC-SHA-256. The hash proves the request was not altered in flight and that the sender knew the shared secret.
Blockchain
Bitcoin mining is a search for an input whose double SHA-256 falls below a target, and a Bitcoin address is RIPEMD-160 of SHA-256 of a public key. Both algorithms in this tool, doing exactly that job.
Digital signatures
Signing algorithms do not sign documents; they sign a document's hash. That is why a broken hash breaks the signature scheme built on it, and why SHA-1 certificates had to be withdrawn.
Software distribution
Package managers pin dependencies by hash so a published version cannot be swapped later. npm's integrity field, Go's checksum database and Nix store paths are all this idea.
Data integrity
Storing a digest alongside a record turns silent corruption into a detectable error. Filesystems such as ZFS and Btrfs do this per block, which is how they notice a disk quietly returning bad data.
Deduplication
Content-addressed storage names each object by its hash, so identical content is stored once no matter how many times it arrives. Git works this way, and so does every container registry.
Security best practices
Never use a general-purpose hash for passwords
This is the most consequential item on the page, so it comes first. Every algorithm in this tool is designed to be fast, and fast is precisely the wrong property for password storage. A modern GPU computes billions of SHA-256 hashes per second, so a stolen table of SHA-256 password hashes is cracked at enormous speed. Adding a salt stops precomputed rainbow tables; it does nothing about raw guessing rate.
Argon2id — the current recommendation. Tunable in time, memory and parallelism, and its memory cost is what defeats GPUs.
bcrypt — well understood, available everywhere, still fine. Note its 72-byte input limit.
PBKDF2 — the conservative choice where a standard requires it. Weakest of the three against GPUs, because it is not memory-hard.
All three are deliberately slow, all three salt automatically, and all three let you raise the cost as hardware improves. That last property is what a plain hash can never offer.
Retire MD5 and SHA-1
MD5 broke in 2004. Collisions take seconds on a laptop, and chosen-prefix collisions let an attacker make two meaningful files match. Use it only to detect accidental corruption, never to prove two files are the same — the MD5 generator exists for the legacy checksums that still need checking.
SHA-1 broke in 2017. Two different PDFs with one digest, and by 2020 a chosen-prefix collision cost roughly $45,000. It survives in Git as a naming scheme rather than a security control.
Both are kept in this tool deliberately — a great many projects still publish MD5 and SHA-1 checksums, and being unable to check them would help nobody. The tool labels them broken wherever they appear.
Choosing among the sound options
SHA-256 by default. Unbroken, fast, and understood by everything you might need to interoperate with.
SHA-512 for extra margin when throughput does not matter. Note it is roughly half the speed of SHA-256 in a browser, and about twice the speed on native 64-bit hardware — the opposite ordering.
SHA-3 when you want a different foundation. Not because SHA-2 is failing, but because depending on one design is a risk in itself.
BLAKE2 when speed matters in native code. As sound as SHA-3 and faster than MD5 outside a browser.
Mind length extension
Given SHA-256(secret + message) and the length of the secret, an attacker can compute SHA-256(secret + message + suffix) for a suffix of their choosing — without ever learning the secret. Anyone authenticating by hashing a secret joined to data is exposed.
Use HMAC rather than concatenation. It exists precisely for this, and every platform ships it.
Or pick a hash that is immune: SHA-224 and SHA-384 truncate their state away, and SHA-3 and BLAKE2 have no extensible state at all.
Compare digests carefully
Compare all of it. Checking the first and last few characters is a habit worth losing; that is exactly the part an attacker would preserve.
Get the checksum from a source the attacker does not control — otherwise you are checking a file against a number supplied by whoever gave you the file.
Use constant-time comparison in code. Not on this page, where both values are on screen and neither is secret, but in any server that compares a submitted MAC — a byte-by-byte early exit leaks the answer through timing.
Frequently asked questions
Is this hash generator free?
Yes. All thirteen algorithms, file hashing of any size, verification, the comparison table, search, copy and download are free, with no account and no usage cap.
Are my files uploaded anywhere?
No, and this matters more here than for most tools. Files are read in chunks by JavaScript running on your own machine and hashed as they go — nothing is sent over the network, stored or logged. You can watch your browser's network panel while hashing a file, or disconnect from the internet after the page loads and keep working. People check hashes of things they do not fully trust, and a tool that uploaded them would defeat the purpose.
Why is MD5 deprecated?
Because finding two different files with the same MD5 takes seconds on an ordinary laptop. Collisions were demonstrated in 2004, and chosen-prefix collisions — where an attacker controls what both files say — became practical soon after. That means an MD5 match no longer proves two files are the same, only that nobody deliberately made them collide. It is still useful for detecting accidental corruption in transit, which is why so many projects still publish MD5 checksums.
Why is SHA-1 deprecated?
The SHAttered attack in 2017 produced two different PDF files with the same SHA-1 digest, and by 2020 chosen-prefix collisions cost around $45,000 of cloud compute — well within reach of anyone motivated. Browsers stopped accepting SHA-1 certificates years before that. Git still uses SHA-1 to name objects, which is content addressing rather than a security boundary, and even Git has been moving to SHA-256.
When should I use SHA-256?
Almost always. It is the default here and the default nearly everywhere else: TLS certificates, container image digests, package manager checksums, code signing and Bitcoin all rest on it. It has no practical attacks after twenty years of scrutiny, it is fast, and every tool you might compare against supports it. Choose something else only when you have a specific reason.
When should I use SHA-512?
When you want more margin than SHA-256's 128-bit collision resistance and throughput does not matter — long-term archival integrity, for instance. On native 64-bit hardware SHA-512 is usually faster than SHA-256; in a browser it is roughly half the speed, because JavaScript has no 64-bit integers and every operation has to be emulated with pairs of 32-bit ones. Worth knowing: SHA-512 is not more secure than SHA-256 in any way that matters today. Both are unbroken.
When should I use SHA-3?
When you want a hash built on completely different mathematics from SHA-2. SHA-3 was standardised in 2015 not because SHA-2 was failing but because it would be unwise for the world to depend on a single design. Its sponge construction also means it has no length-extension weakness at any output size, where SHA-256 and SHA-512 do. The cost is speed: SHA-3 is the slowest family in this tool.
What is BLAKE2 and why is it not faster here?
BLAKE2 was a SHA-3 finalist that lost the competition and won the deployment: it is as sound as SHA-3 and, in native code, faster than MD5. Argon2 uses it internally and content-addressed storage systems favour it. In a browser that advantage disappears, because BLAKE2b's 64-bit rotations have to be emulated in JavaScript. The measured figures in the comparison table are honest about this — they describe this implementation, not the algorithm in the abstract.
What is RIPEMD-160 used for?
Almost entirely Bitcoin. A Bitcoin address is RIPEMD-160 of SHA-256 of a public key, so every wallet and block explorer needs it. It was designed in Europe as an open alternative to the NSA-designed SHA family and has never been broken the way MD5 and SHA-1 were. Its weakness is size: 160 bits gives only 80-bit collision resistance, which is the same bound that made SHA-1 fall.
Can I hash large files?
Yes, with no size limit imposed by this tool. Files are streamed in chunks and hashed as they are read, so a file larger than your available memory still works and you get a progress bar throughout. A gigabyte takes around six seconds with SHA-256. Choosing Generate All hashes the same bytes through all thirteen algorithms in a single pass, which costs one read but thirteen times the arithmetic — expect it to be noticeably slower.
How do I verify a downloaded file?
Choose the algorithm the publisher used — usually SHA-256 — drop the downloaded file onto this page, then paste their published checksum into the Verify panel. A match means the bytes are identical to what they hashed. The important caveat is where the checksum came from: if you took it from the same page as the download, an attacker who replaced one could replace the other. A checksum is only as trustworthy as its source.
What is the difference between hashing and encryption?
Encryption is reversible by design — that is what the key is for. Hashing is one-way: a digest is a fixed-size fingerprint, and the original cannot be recovered from it because most of the information is discarded. Hashing a gigabyte gives 32 bytes, and those 32 bytes cannot contain the gigabyte. If someone talks about decrypting a hash, they have confused the two.
Can a hash be reversed?
Not by computation. What can happen is guessing: if the input is short and predictable — a common password, a phone number, a date — an attacker can hash every candidate and look for a match. That is not reversal, it is a dictionary attack, and it works because the input space is small rather than because the hash is weak. It is exactly why password storage needs a deliberately slow function with a salt.
Should I hash passwords with SHA-256?
No, and this is the most consequential mistake on this page. General-purpose hashes are designed to be fast, and fast is precisely wrong for passwords — a modern GPU computes billions of SHA-256 hashes per second, so a stolen database of SHA-256 password hashes falls quickly. Use bcrypt, Argon2 or PBKDF2. They are deliberately slow, they take a per-user salt so identical passwords do not produce identical hashes, and their cost can be raised as hardware improves.
What is a hash collision?
Two different inputs producing the same digest. Collisions must exist — there are infinitely many possible inputs and a finite number of digests — so the security question is not whether they exist but whether anyone can find one. For SHA-256 the best known approach needs about 2^128 operations, which is not achievable. For MD5 it takes seconds, and for SHA-1 it has been done.
Why do two similar files have completely different hashes?
That is the avalanche effect, and it is deliberate. Changing a single bit of the input flips roughly half the bits of the output, so 'dog' and 'cog' produce digests with nothing visibly in common. It is what makes hashes useful for integrity: any change, however small, is obvious. It also means a hash cannot tell you how much a file changed — only that it did.
What is length extension, and does it affect me?
Given the SHA-256 of a secret followed by a message, an attacker can compute the SHA-256 of that message plus a suffix of their choosing, without knowing the secret. It affects anyone who builds authentication by hashing a secret joined to data. The fix is HMAC, which is designed around the problem. SHA-224, SHA-384, all of SHA-3 and BLAKE2 are immune — the first two because truncation hides the internal state, SHA-3 because a sponge has no state to extend.
Does the same input always give the same hash?
Yes, always, everywhere. That determinism is the entire basis of the tool: a hash computed here matches one from shasum, openssl, certutil or any correct implementation, byte for byte. Text is hashed as UTF-8, which is what command-line tools do — if a digest here disagrees with one elsewhere, a character encoding or a trailing newline is almost always the reason.
Why does my file hash differ from the one in the terminal?
For a file, it should not — the bytes are the bytes. For text, the usual culprits are a trailing newline (echo adds one; use printf or echo -n to compare) and line endings, since a file saved with Windows CRLF hashes differently from the same text with Unix LF. Character encoding is the third: this tool uses UTF-8.
Does this tool work offline?
Once the page has loaded, yes. All hashing happens locally, so you can disconnect and keep working — which is a reasonable thing to do before hashing something sensitive.
Keep going
Tools that pair with this one
Same privacy model — everything below runs in your browser too.