Skip to content
secureSHA-2 · 512 bits · 2001

SHA-512

The big sibling of SHA-256. Faster on 64-bit hardware, larger output, identical security properties.

By ·

SHA-512 produces a 512-bit digest using 64-bit word operations. On 64-bit CPUs without SHA-NI, it's often faster than SHA-256 because it processes the message in 128-byte blocks (versus SHA-256's 64-byte blocks) with native 64-bit arithmetic. Pick SHA-512 when you want a hash whose output is wide enough to use directly as a 256-bit symmetric key plus a 256-bit MAC tag, or when you're targeting hardware that's been benchmarked to be faster on the 512 variant. For most web-tier work, SHA-256 is the safer default because its smaller output makes log lines / database columns / OpenAPI specs less awkward.

Recommended uses

  • ·Hashing on 64-bit servers without SHA-NI extensions
  • ·Generating wide pseudorandom keying material

Known attacks / caveats

  • ·Length-extension attack on the bare construction; use HMAC-SHA512

Designed by

NSA, published 2001.

Hash some text →Compare against other algorithms →

Frequently asked questions

Is SHA-512 secure in 2026?
Yes. SHA-512 has no practical breaks as of 2026. Caveats worth knowing: Length-extension attack on the bare construction; use HMAC-SHA512.
What is SHA-512 used for?
Hashing on 64-bit servers without SHA-NI extensions. Generating wide pseudorandom keying material.
How long is the output of SHA-512?
512 bits, which is 64 bytes, or 128 characters when written as hexadecimal. The length is fixed regardless of how large the input is.
Can SHA-512 be used to hash passwords?
No, and this is the most consequential mistake people make with it. SHA-512 is a fast general-purpose hash, and fast is exactly the wrong property for passwords: it lets an attacker with a stolen database test billions of guesses. Use a purpose-built password hashing function such as Argon2id instead.
Who created SHA-512?
NSA, published in 2001.