What Is a Cryptographic Hash?
A cryptographic hash function transforms input bytes into a fixed-length message digest. The same input bytes processed with the same algorithm always produce the same digest, while even a small change in the input will normally produce a very different output. Hashes are commonly used for integrity checks, fingerprints, protocol building blocks and digital-signature workflows.
This tool uses the browser's Web Crypto API and encodes text as UTF-8 before hashing it. The Hex and Base64 options only change how the digest bytes are displayed; they do not change the underlying hash calculation.
How to Use the Hash Generator
Enter text, choose SHA-256, SHA-384, SHA-512 or SHA-1, select Hex or Base64, and choose Generate Hash. For a file, use the file picker and choose Generate File Hash. The file is read by the browser and hashed locally.
For reproducible verification, both sides of a comparison must use the exact same input bytes, character encoding, hash algorithm and output representation. Two visually similar text strings can hash differently if their bytes differ—for example because of line endings, Unicode normalization or invisible whitespace.
SHA-256, SHA-384 and SHA-512
SHA-256, SHA-384 and SHA-512 are members of the SHA-2 family defined by NIST's Secure Hash Standard. They produce 256-bit, 384-bit and 512-bit digests respectively. The best choice depends on the protocol, interoperability requirement and security design; a longer digest is not automatically better for every use case.
Why SHA-1 is different
SHA-1 produces a 160-bit digest and was widely deployed in older systems. Its collision resistance has been broken in practice, which is why it should not be selected for new digital-signature, certificate, integrity or other collision-sensitive security designs. NIST has announced a transition away from SHA-1 for all applications, with the transition targeted for completion by December 31, 2030.
Hashing is not encryption
Encryption is designed to protect data while allowing authorized recovery with a key. Hashing creates a one-way digest intended for comparison, integrity checks and other cryptographic constructions. There is no decryption step that restores the original input from a standard SHA digest.
Generic SHA hashes are not password storage
A fast generic SHA function is not a complete password-storage design. Password systems should use a password-specific, deliberately expensive password-hashing scheme such as Argon2, scrypt or bcrypt, along with unique salts and secure server-side credential handling. This browser tool is intended for hashing and verification workflows, not for implementing an authentication database.
Text hashing vs. file hashing
Text hashing converts the characters you enter to UTF-8 bytes first. File hashing reads the file's raw bytes directly. That distinction matters: hashing the visible text inside a document is not the same as hashing the file that stores the document, because the file can contain metadata, compression, formatting and other bytes that are not visible on screen.
Worked example
The UTF-8 text hello hashed with SHA-256 produces a specific 256-bit digest. If even one character changes—such as using Hello with a capital H—the resulting digest changes. This is the basic reason hashes are useful for detecting content changes.
Methodology and limitations
- The tool uses
crypto.subtle.digest()from the Web Crypto API. - Text is converted to UTF-8 with
TextEncoderbefore hashing. - File hashing reads the selected file as raw bytes in the browser.
- Hex and Base64 are output encodings of the same digest bytes.
- The tool does not create HMACs, digital signatures, password hashes or key-derivation outputs.
- A matching digest confirms that the compared inputs produced the same hash under the same algorithm; it does not by itself authenticate who created the data.
Standards and references
Related Utiliverse Tools
Last reviewed: September 30, 2026 · Algorithm guidance and references reviewed against current NIST publications.
Hash Generator FAQ
Which algorithms are supported?
This version supports SHA-1, SHA-256, SHA-384 and SHA-512 where the browser's Web Crypto API supports them.
Which algorithm should I use for a new application?
For a new security-sensitive design, use an algorithm required or recommended by the protocol or standard you are implementing. SHA-256 is a widely interoperable SHA-2 option. SHA-1 should not be selected for new collision-sensitive security designs.
Why is SHA-1 still available?
It is included for legacy compatibility, testing and verification of older systems or checksums. NIST recommends transitioning away from SHA-1 for security applications.
What is SHA-256?
SHA-256 is a SHA-2 family hash function that produces a 256-bit digest.
Is hashing the same as encryption?
No. Hashing is a one-way digest operation, while encryption is designed to be reversible with an authorized key.
Is my input or file uploaded?
The hash calculation is performed locally in your browser. The entered text or selected file is not submitted to a Utiliverse server by the hashing function.
Can I use this to store passwords?
Do not use a generic SHA digest as a password-storage design. Use a password-specific hashing scheme such as Argon2, scrypt or bcrypt with unique salts and appropriate server-side controls.
What is the difference between Hex and Base64?
They are two ways to represent the same digest bytes. Changing Hex to Base64 does not change the underlying hash.
Can I hash a file?
Yes. Select a local file and use Generate File Hash. The browser reads the file bytes locally and hashes them with the selected algorithm.