Home/Hash Generator

Hash Generator

Generate cryptographic hashes using your browser's native SubtleCrypto API. Zero network requests — your data stays local.

0 chars · 0 bytes
Advertisement

Cryptographic Hash Functions

Hash Function Properties (One-Way)

Input (any length)"Hello, World!"SHA-256Compression + Mixing256 rounds of opsFixed-Length Outputa591a6d40bf... (64 hex)

A cryptographic hash function is a one-way mathematical function that maps data of arbitrary size to a fixed-size bit string (the "hash" or "digest"). The SHA-2 family (SHA-256, SHA-384, SHA-512) is defined in FIPS 180-4 and is widely used in TLS certificates, code signing, and password hashing.

SHA Algorithm Comparison

AlgorithmOutput (bits)Block SizeStatusUse Case
SHA-1160512 bits⚠️ DeprecatedLegacy only — CVE-2017-15361
SHA-256256512 bits✅ SecureTLS, GPG, Bitcoin, JWT
SHA-3843841024 bits✅ SecureTLS 1.3, ECDSA P-384
SHA-5125121024 bits✅ SecurePassword hashing, archival
SHA-3/2562561088 bits✅ SecureQuantum-resistant alternative

Key Properties of Hash Functions

  • Deterministic: The same input always produces the same hash output.
  • One-Way (Pre-image Resistant): It is computationally infeasible to reverse a hash back to its original input.
  • Avalanche Effect: A single bit change in the input completely changes the output hash.
  • Collision Resistant: It is computationally infeasible to find two different inputs with the same hash.
  • Fixed Output Size: Regardless of input size, SHA-256 always produces a 256-bit (32-byte) output.

⚠️ SHA-1 is Broken

SHA-1 collision attacks have been demonstrated (SHAttered, 2017). Do not use SHA-1 for digital signatures, certificates, or security-sensitive applications. Use SHA-256 or higher.