Compyrix logo

Hash Generator

Generate MD5, SHA-1, SHA-256, and SHA-512 hashes.

MD5
SHA-1
SHA-256
SHA-512

A cryptographic hash function takes an arbitrary input (text, file, password) and produces a fixed-size string of bytes called a digest or hash. The same input always produces the same hash, and even a tiny change in input produces a completely different hash — the "avalanche effect". Our free Hash Generator computes MD5, SHA-1, SHA-256, and SHA-512 hashes of any text.

Simply type or paste your text in the input. All four hashes compute instantly. Each one is shown in its standard hexadecimal encoding (lowercase hex characters). Use the Copy button next to any hash to copy it to your clipboard.

Use cases: verifying that a downloaded file matches its published checksum (compare file SHA-256 to the published one), detecting accidental changes to text or configuration, creating deterministic identifiers that do not reveal the original value, and as a building block in Merkle trees and blockchain data structures.

Security notice: MD5 and SHA-1 are broken for cryptographic security. Use SHA-256 or SHA-512 for any security-relevant purpose, and never use any plain hash — even SHA-256 — for password storage. Passwords require a slow, salted, memory-hard algorithm like bcrypt, scrypt, or Argon2 to resist offline brute-force attacks.

Frequently Asked Questions

Which hash algorithm should I use?
SHA-256 is the modern default and is suitable for almost all general-purpose hashing. SHA-512 is more conservative (512-bit vs. 256-bit output) and may be faster than SHA-256 on 64-bit CPUs. Avoid MD5 and SHA-1 for new applications — they exist here only for compatibility with legacy systems.
Can I reverse a hash to get the original text?
Not directly — cryptographic hashes are designed to be one-way functions. However, weak hashes (especially MD5) and common inputs like passwords and short strings can often be looked up in precomputed "rainbow tables" or cracked with brute force. Use salting and dedicated password hashing algorithms for passwords.
Why are hash outputs different lengths?
MD5 produces 128 bits = 32 hex characters. SHA-1 produces 160 bits = 40 hex chars. SHA-256 = 256 bits = 64 hex chars. SHA-512 = 512 bits = 128 hex chars. Each hex digit represents 4 bits, so length in chars = bits / 4.
Can I hash files (images, documents) with this tool?
The current tool only hashes text input. File hashing is a planned feature for our image/file tools suite. In the meantime, you can compute file hashes locally on the command line: sha256sum filename on Linux/Mac or certutil -hashfile filename SHA256 on Windows.

Related Tools