Skip to main content
riqo.ioTools for big ideas

SHA-256 and SHA-512 hash generator

Compute SHA-256 or SHA-512 digests of UTF-8 text as lowercase hexadecimal.

Operation

Note

This is not a password hasher, cracker, HMAC or file hasher.

Result

Description

Computes deterministic cryptographic hashes of the supplied text. It is not a password hasher and does not perform cracking, HMAC, file hashing, MD5 or SHA-1.

Instructions

Enter text and choose SHA-256 or SHA-512. The same text and algorithm always produce the same digest.

Use cases

Compare textual checksums

Verify SHA-256/SHA-512 examples

Generate deterministic digests during development

Examples

SHA-256

Input

abc

Output

ba7816bf8f01cfea...

Frequently asked questions

Can I use this for password storage?

No. Passwords require dedicated salted, costly algorithms such as Argon2 or bcrypt.

Does it support HMAC?

No. V1 computes plain SHA-256 and SHA-512 only.

In-depth guide

Hash functions: digests, integrity and security

Cryptographic hash properties, SHA, collisions, HMAC, password hashing and the difference from encryption.

What a hash function does

A hash function maps arbitrary-length input to a fixed-length digest. It is deterministic: identical input gives identical output, while a well-designed cryptographic hash exhibits a broad change in digest when the input changes slightly.

A digest is derived data, not compressed text that can be expanded back into the message. One-way behavior underpins many integrity, signature and content-identification applications.

Preimage, second preimage and collisions

Security properties are distinct: preimage resistance, second-preimage resistance and collision resistance. A collision occurs when two different inputs share a digest; generic collision search for an n-bit hash follows roughly the 2^(n/2) birthday bound.

Digest size and known cryptanalysis therefore matter. MD5 and SHA-1 are unsuitable where cryptographic collision resistance is required, even though legacy or non-adversarial checksum uses may still exist.

The SHA family and algorithm choice

SHA-256 and SHA-512 are SHA-2 functions and remain common choices for integrity and many protocols. SHA-3 uses a different construction and provides another standardized family with different internal properties.

Choice depends on protocol requirements, interoperability, reliable library support and security goals rather than bit count alone. Avoid custom hashes or non-standard compositions without specific analysis.

Hashes, checksums and HMAC

An unauthenticated hash only detects accidental change when the expected digest arrives through a trusted path. An attacker able to alter both data and digest can simply calculate a new hash.

HMAC combines a hash with a secret key to provide message authenticity and integrity between parties sharing that key. Traditional checksums are mainly designed for accidental corruption rather than active attackers.

Passwords: why fast hashes are wrong

Passwords have limited entropy and can be guessed offline. Fast functions such as SHA-256 enable enormous numbers of attempts and are therefore inappropriate for password storage even when a simple salt is added.

Use adaptive password hashing functions such as Argon2id, scrypt or bcrypt with unique salts and calibrated cost parameters. Salts defeat precomputed tables but do not replace computational cost.

Hashing is not encryption

Encryption is reversible with a key and aims to provide confidentiality. Hashing is not designed to recover the original message and serves different goals such as fingerprints and integrity.

Choose the primitive from the threat model: authenticated encryption for confidential data, HMAC for keyed message authentication, password hashing for credentials and cryptographic hashes for public digests.

Open the full guide