What is hash generator?
Hash functions turn any input into a short fixed length string. The same input always gives the same hash, and a tiny change gives a completely different one.
They are used to check that a download is intact, to compare values without storing them and as part of signatures.
How to use the hash generator
- Type or paste text.
- Press Calculate.
- Copy the hash you need.
How the hash generator works
Text is encoded as UTF 8 and passed to the Web Crypto API, which returns the digest as bytes. The bytes are shown as hexadecimal.
Worked example
Common uses of the hash generator
- Checking that a downloaded file matches its published checksum.
- Comparing two pieces of text without showing them.
- Creating cache keys and short fingerprints.
- Learning how hash functions behave.
- Verifying data was not changed in transit.
Tips and common mistakes
Do not store passwords with plain SHA hashes. Use bcrypt, scrypt or Argon2 with a salt.
MD5 and SHA 1 are broken for security. Use SHA 256 or better.
Background: what to know before you rely on it
A cryptographic hash function takes any input and returns a fixed size string, with three key properties: the same input always gives the same output, a tiny change in input changes the output completely, and it is not practical to work backward from the output. SHA 2 functions such as SHA 256 are widely used in security, and SHA 1 is considered weak for signatures. A plain hash is not enough for passwords because attackers can try billions of guesses per second. Password storage needs slow, salted algorithms like bcrypt or Argon2. Hashes are also not encryption, because there is nothing to decrypt.
Private, free and fast
This tool runs entirely in your browser. What you type or choose is not uploaded to a server and is not saved after you close the page, which keeps it fast and private. It is free to use as often as you like. See more in all developer tools, or browse the full list of tools.
Field by field guide
- Text: Type or paste your text here. Use a new line for each entry where the label says so.
Change one field at a time to see how the result responds, and use the worked example above to check that you get the same answer.
Choosing a hash function
A hash turns any input into a fixed length fingerprint. The same input always gives the same hash, and a tiny change gives a completely different one. Hashes cannot be reversed to recover the input.
Expert tips
- Use SHA 256 for checksums and integrity checks. MD5 and SHA 1 are fast but broken against deliberate collisions, so they are fine for spotting accidental changes only.
- Never store passwords with a plain hash. Use a slow password hash such as bcrypt, scrypt or Argon2 with a unique salt.
- Compare hashes character by character, or paste both into a text compare tool, to confirm a download matches the publisher value.
- A SHA 256 result is 64 hexadecimal characters and a SHA 1 result is 40.
- Whitespace counts. A trailing newline changes the hash, so copy text exactly.
A hash proves a file is unchanged only if you obtained the expected hash from a trusted place, such as the official site over HTTPS.
Frequently asked questions
What is a hash?
A fixed length fingerprint of data.
Can a hash be reversed?
Not directly. Weak inputs can be guessed.
Why no MD5?
The browser does not provide MD5 and it is not secure.
Guides that go with this tool
Related tools
Password Strength Checker
Type a password to see a strength rating, estimated entropy in bits and a rough crack time. It checks...
Developer ToolsJSON Formatter and Validator
Paste your JSON and the tool checks that it is valid, then formats it with indentation or compresses it...
Developer ToolsBase64 Encoder and Decoder
Base64 turns text or bytes into a safe string of letters and numbers. Choose encode or decode, paste...
Developer ToolsURL Encoder and Decoder
URL encoding replaces unsafe characters with a percent sign and two hex digits so a link works...
Developer ToolsRegex Tester
Enter a pattern, flags and test text. The tester lists every match with its position and capture groups...
Developer ToolsCSS Minifier
Paste your CSS and the minifier removes comments and extra whitespace to make the file smaller, with the...
Results are for information and education. For legal, financial, medical or security decisions, check with a qualified professional. Do not paste live secrets into any website.