Need a strong password instead? Try our Password Generator
What is a SHA hash?
SHA-256, SHA-384, and SHA-512 belong to the SHA-2 family of cryptographic hash functions, standardized by NIST (FIPS 180-4). Each takes any input — text, a file's contents, anything — and produces a fixed-length "digest" that looks like random characters. The same input always produces the same hash, but there's no way to reverse a hash back into the original input. That makes hashes useful for verifying a file hasn't been altered (checksums), confirming data integrity, and as a building block in digital signatures and systems like Git and Bitcoin.
SHA-256 vs SHA-384 vs SHA-512: which should I use?
| SHA-256 | 256 bits (64 hex characters) | The most widely used and compatible default — this is what most checksums, APIs, and file-verification tools expect. |
| SHA-384 | 384 bits (96 hex characters) | A truncated variant of SHA-512, sometimes required by specific compliance or protocol standards. |
| SHA-512 | 512 bits (128 hex characters) | A larger security margin than SHA-256, and often faster on 64-bit systems — a good choice when you specifically need SHA-2's strongest option. |
Is it safe to hash sensitive data with this tool?
Yes — hashing happens entirely in your browser using the Web Crypto API. Nothing you type is ever uploaded, logged, or stored on a server.
What is SHA-256 used for?
Verifying downloaded files haven't been corrupted or tampered with, confirming data integrity, digital signatures, and as a core building block in systems like Git and Bitcoin. It is not, by itself, a good way to store passwords — use bcrypt, scrypt, or Argon2 for that.
Can I get the original text back from a hash?
No. Hashing is one-way by design — there is no way to reverse a SHA-256/384/512 hash back into the input that produced it.
SHA-256、SHA-384、SHA-512 之间有什么区别?
它们同属 SHA-2 家族,底层设计一致,主要区别在于输出长度和运算速度。SHA-256 输出 256 位,是使用最广泛的默认选项。SHA-512 输出 512 位,安全裕度更大,在 64 位系统上往往运算更快。SHA-384 是 SHA-512 内部运算的截断版本,输出 384 位,主要用于某些标准或协议明确要求这个长度的场景。日常用途(文件校验、完整性核对)用 SHA-256 就足够;如果你specifically想要 SHA-2 里安全裕度最大的选项,就选 SHA-512。
SHA-512 比 SHA-256 或 SHA-384 更安全吗?
从理论安全裕度来看,是的。对于 n 位的哈希,通用的碰撞抵抗力大约是 2^(n/2)——SHA-256 约为 2¹²⁸,SHA-384 约为 2¹⁹²,SHA-512 约为 2²⁵⁶,所以 SHA-512 的安全裕度最大。但实际使用中这个差距通常不重要:2¹²⁸ 已经远超现实中任何可行的计算量,而且 SHA-2 家族目前没有任何已知的实际可行攻击。日常使用 SHA-256 完全没问题;只有当你specifically需要更大的理论安全裕度,或者某个协议明确要求时,才需要选 SHA-512。