A hash function takes input data of any size and produces a fixed-size string of characters, called a hash or digest. The same input always produces the same hash, but even a tiny change in the input produces a completely different hash. Hash functions are one-way: you cannot reverse a hash to recover the original input.
🔐 SHA-256 (Recommended)
Part of the SHA-2 family, SHA-256 produces a 256-bit (64-character hex) hash. It is widely used for password hashing, digital signatures, and blockchain applications. SHA-256 is currently considered cryptographically secure.
Example: e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855
🔒 SHA-512
Also part of SHA-2, SHA-512 produces a 512-bit (128-character hex) hash. It offers higher security than SHA-256 but is slower to compute. Suitable for applications requiring maximum collision resistance.
Example: cf83e1357eefb8bdf1542850d66d8007d620e4050b5715dc83f4a921d36ce9ce...
⚠️ SHA-1 (Legacy)
Produces a 160-bit (40-character hex) hash. SHA-1 is deprecated due to known collision vulnerabilities. Only use SHA-1 when required for compatibility with legacy systems. Do not use for security-critical applications.
Example: da39a3ee5e6b4b0d3255bfef95601890afd80709
⚠️ MD5 (Legacy)
Produces a 128-bit (32-character hex) hash. MD5 is cryptographically broken and should not be used for security purposes. It remains useful for checksums and non-security applications like duplicate file detection.
Example: d41d8cd98f00b204e9800998ecf8427e