Hash Generator - MD5, SHA-1, SHA-256, SHA-512 Online
—————Five Hashes of the Same Input
Type or paste text and the tool shows its MD5, SHA-1, SHA-256, SHA-384 and SHA-512 digests together, each as lower-case hex with its own copy button. That is handy when you have a checksum but no label saying which algorithm produced it: the length tells you.
| Algorithm | Bits | Hex length | Hash of "hello" (first 16 chars) |
|---|---|---|---|
| MD5 | 128 | 32 | 5d41402abc4b2a76… |
| SHA-1 | 160 | 40 | aaf4c61ddcc5e8a2… |
| SHA-256 | 256 | 64 | 2cf24dba5fb0a30e… |
| SHA-384 | 384 | 96 | 59e1748777448c69… |
| SHA-512 | 512 | 128 | 9b71d224bd62f378… |
Paste hello (no newline) to check the tool against these
values. Text is encoded as UTF-8 before hashing, which is what
sha256sum, Python's hashlib and Node's
crypto do with a UTF-8 string.
Getting the Same Hash as Your Code
A hash changes completely if a single byte changes, so the input has to match exactly. The usual mismatches:
- Trailing newline.
echo "hello"adds\n. Useprintf 'hello'orecho -n. - Line endings. A file saved on Windows has
\r\n. Browsers turn line breaks in a text box into\n, so a CRLF file and the same text pasted here hash differently. - Unicode normalisation. "café" typed with a single é and "café" built from e plus a combining accent look identical but are different bytes, so they produce different hashes.
- Hex vs Base64. Some APIs and Subresource Integrity attributes show the digest in Base64. The bytes are the same; only the notation differs.
Which One to Pick
MD5 and SHA-1 are fast and everywhere, but collisions can be
manufactured for both, so they are only fit for spotting accidental
changes. SHA-256 is the default for new work. SHA-384 is SHA-512
truncated with different starting values, and shows up mainly in
TLS cipher suites and integrity="sha384-..." attributes.
None of these are suitable for storing passwords on their own: they are
designed to be fast, which helps attackers guess. Use bcrypt, scrypt or
Argon2 for passwords.
Each algorithm also has its own page with more detail: MD5, SHA-1, SHA-256 and SHA-512. To sign a message with a secret key, use the HMAC generator. If you need to get the original data back later, a hash is the wrong tool; use an encoding such as Base64 or proper encryption.
Related Tools
JWT Decoder
Decode JSON Web Tokens and inspect header, payload and signature.
Base64 Encode / Decode
Encode text to Base64 or decode Base64 strings back to plain text.
URL Encode / Decode
Percent-encode or decode URLs and query-string parameters safely.
MD5 Hash Generator
Generate MD5 hashes from text for checksums and legacy systems.