Hash Generator
SHA-256, MD5, SHA-1, SHA-384 and SHA-512 of text or files, HMACs, and checksum verification. Hashing happens on your device; nothing is uploaded.
The key stays on this page: it isn't saved or sent anywhere.
Results
Type text or choose a file. Hashes appear as you type.
What is a hash generator for?
A cryptographic hash turns any input, a word or a 10 GB disk image, into a short fixed-length fingerprint. The same input always gives the same fingerprint, and changing a single bit gives a completely different one. That makes hashes the standard way to check a download isn't corrupted or tampered with, to tell whether two files are identical without comparing them byte by byte, and, with a secret key (HMAC), to sign API requests and webhooks.
How it works
- Type or paste text, or choose or drop a file. Hashes for every selected algorithm appear as you type.
- Switch algorithms on or off, and pick hex (upper or lower case), Base64 or binary output.
- To check a download, paste the publisher's checksum into Verify a checksum: the matching card turns green.
- For a keyed signature, tick HMAC and enter the secret. Copy one result, or Copy all.
How to verify a file checksum
Software publishers list a SHA-256 (sometimes SHA-512 or MD5) value next to each download. If the file you received hashes to the same value, it is bit-for-bit the file they published. To check:
- Download the file and copy the checksum from the publisher's site, ideally from a page served over HTTPS rather than from a mirror.
- Choose or drop the file above. A file over 64 MB shows a progress bar. With only SHA-256 switched on, a 4 GB ISO takes roughly a minute on a recent laptop, longer on a phone.
- Paste the checksum into Verify a checksum. You can paste the bare hash or a whole line from a SHA256SUMS file, shasum, certutil or Get-FileHash; the hash is picked out and case doesn't matter.
- Match means the file is intact. Doesn't match means it was damaged in transit, is a different version, or was altered: delete it and download again.
A matching checksum proves the file is the one the checksum was made from. It doesn't prove who made it: if an attacker controls the download page, they can change both. That is what signed checksums (GPG, Sigstore) are for.
MD5 vs SHA-1 vs SHA-256 vs SHA-512
| Algorithm | Bits | Hex chars | Security today | Typical use |
|---|---|---|---|---|
| MD5 | 128 | 32 | Broken: collisions take seconds on a laptop | Spotting accidental corruption, legacy systems, cache keys |
| SHA-1 | 160 | 40 | Broken: practical collisions since 2017 | Git object IDs, older checksums and certificates |
| SHA-256 | 256 | 64 | Secure, the default choice | Download checksums, signatures, certificates, HMAC, Bitcoin |
| SHA-384 | 384 | 96 | Secure; immune to length extension | TLS cipher suites, Subresource Integrity (sha384-…) |
| SHA-512 | 512 | 128 | Secure, longest output | Checksums for OS images (e.g. Debian's SHA512SUMS) |
Collisions (two different inputs with the same hash) were demonstrated for MD5 in 2004 and for SHA-1 in 2017 (the "SHAttered" PDFs). Neither should be used where an attacker could choose the input, such as signatures or certificates. Both still catch accidental corruption, which is why old download pages list them. For anything new, use SHA-256.
Worked examples
Type these into the box to see each property for yourself:
- abc → SHA-256 ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad, the official test vector from the SHA-2 standard.
- abc plus a line break → edeaaff3f1774ad2…. One invisible character changes everything; this is what echo abc | sha256sum hashes.
- An empty input still has a hash: MD5 d41d8cd98f00b204e9800998ecf8427e. If a "checksum" you see is exactly that value, someone hashed nothing.
- hello and Hello share nothing: MD5 5d41402a… vs 8b1a9953…. Hashes are case-sensitive about their input.
- HMAC-SHA256 of The quick brown fox jumps over the lazy dog with key key → f7bc83f430538424b13298e6aa6fb143ef4d59a14946175997479dbc2d1a3cd8.
Hashing from the command line
Every operating system can hash a file without installing anything. These give the same values as this page:
| System | SHA-256 command | Notes |
|---|---|---|
| Linux | sha256sum file.iso | md5sum, sha1sum, sha512sum work the same way |
| macOS | shasum -a 256 file.iso | md5 file.iso for MD5 |
| Windows (cmd) | certutil -hashfile file.iso SHA256 | MD5, SHA1, SHA384, SHA512 also accepted |
| Windows (PowerShell) | Get-FileHash file.iso | SHA256 by default; add -Algorithm MD5 etc. |
| Text, any Unix shell | printf '%s' 'abc' | sha256sum | echo adds a line break; printf doesn't |
Common mistakes
- Hidden line breaks. Hashing text copied from a terminal or a file often includes a trailing newline. The page warns you when your text ends with one.
- Windows line endings. A text box always uses LF line breaks. If the original was saved on Windows (CRLF), choose CRLF under Line breaks, or better, hash the file itself.
- Comparing different algorithms. A 64-character checksum is SHA-256, 128 is SHA-512, 32 is MD5. The verifier tells you if the algorithm you need is switched off.
- Using a plain hash for passwords. Fast hashes are easy to brute-force. Generate strong passwords with our password generator and let your login system store them with Argon2 or bcrypt.
- Calling hashing "encryption". Nothing can be decrypted from a hash. To make data readable in a different form, you want an encoding such as Base64 instead.
HMAC: hashes with a secret key
An HMAC mixes a secret key into the hash in a way defined by RFC 2104, so the result can't be forged without the key. Payment providers, GitHub and Slack sign their webhooks with HMAC-SHA256, and AWS signs every API request this way. To debug a failing webhook signature, paste the raw request body here exactly as received, enter the signing secret, and compare the HMAC-SHA256 with the header (hex or Base64, depending on the provider). JSON Web Tokens signed with HS256 use the same construction; our JWT decoder can check those signatures for you.
Related developer tools: create random identifiers with the UUID generator, encode values for links with the URL encoder, or compare two texts line by line with the diff checker.
Frequently asked questions
How do I check the SHA-256 checksum of a downloaded file?
Choose or drop the file above, then paste the checksum from the download page into 'Verify a checksum'. The page says Match and highlights the SHA-256 card if the file is identical to the one the publisher hashed. If it doesn't match, the download is corrupt or was changed, so download it again from the official site.
Is my file or text uploaded anywhere?
No. Hashing runs in your browser with Web Crypto and JavaScript, in a background thread on your own device. Nothing you type or choose is sent to a server, which is also why it works for files of any size without waiting for an upload.
Can it hash very large files, like a 4 GB ISO?
Yes. Files up to 64 MB are read in one go and hashed with your browser's built-in crypto. Bigger files are read in 4 MB pieces, so memory use stays small however large the file is, with a progress bar, speed and a Cancel button. Switching off algorithms you don't need makes it faster.
Why is my hash different from the one sha256sum or certutil gives?
Almost always the input differs by an invisible character. 'echo abc | sha256sum' hashes 'abc' plus a line break; use 'echo -n' or 'printf' for the bare text. Text from a Windows file has CRLF line breaks while a text box uses LF: set Line breaks to CRLF here. And a file hashed as a file is not the same as its contents pasted as text, so hash the file itself.
What's the difference between MD5, SHA-1 and SHA-256?
Output size and security. MD5 gives 128 bits (32 hex characters) and SHA-1 gives 160 bits (40); both have practical collision attacks, so they're only fit for spotting accidental corruption. SHA-256 gives 256 bits (64 hex characters) and has no known practical attack; it is the usual choice for checksums, signatures and certificates. SHA-384 and SHA-512 are longer members of the same SHA-2 family.
Can a hash be reversed or decrypted back to the original text?
No. A hash is not encryption, so there is no key and nothing to decrypt. Sites that claim to 'decrypt MD5' look the hash up in tables of hashes of common words and leaked passwords. That works for short, common inputs, which is why a plain hash is a poor way to protect a password.
What is an HMAC and when do I need one?
An HMAC is a hash computed with a secret key, so only someone who knows the key can produce or check it. APIs and webhooks (Stripe, GitHub, Slack, AWS) use HMAC-SHA256 signatures to prove a request came from them. Tick 'HMAC with a secret key', enter the key as text, hex or Base64, and compare the result with the signature header you received.
Is SHA-256 safe for storing passwords?
Not on its own. SHA-256 is designed to be fast, so an attacker with a leaked database can try billions of guesses per second. Passwords need a slow, salted algorithm made for the job: Argon2id, scrypt or bcrypt, as recommended by OWASP. Use this tool for checksums, fingerprints and HMACs, not password storage.
Why do hex and Base64 show different text for the same hash?
They are two spellings of the same bytes. Hex uses two characters per byte (64 characters for SHA-256), Base64 packs the same 32 bytes into 44 characters. Checksums on download pages are almost always hex; HTTP headers such as Content-Digest and Subresource Integrity use Base64. Uppercase and lowercase hex are equal, and the verifier accepts both.
Does it handle Unicode and emoji?
Yes. Text is converted to UTF-8 bytes before hashing, the same encoding Linux and macOS terminals and almost every programming language use, so 'café' or an emoji hashes to the same value here as in Python or Node.js. A file is hashed exactly as stored, byte for byte.
What does a SHA-256 hash look like?
64 hexadecimal characters (0–9 and a–f), for example ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad, which is the SHA-256 of 'abc'. Changing the input even slightly gives a completely different 64-character value, and the length is the same whether you hash one letter or a 10 GB file.
Related tools
More free, private, browser-based utilities — no upload, no sign-up.