Skip to content

↑↓ navigate ↵ open Esc close Search runs locally

MD5 Hash Generator (Text & Files)

Generate the MD5 hash of any text or file instantly, and check a file against an MD5 checksum. Everything runs in your browser.

  • Runs in your browser
  • Nothing is uploaded
  • Free, no sign-up
Algorithms
0 BUTF-8
Hashes

    Runs in your browser. Files are never uploaded. Tip: drop a file to verify a download

    How to use the MD5 tool#

    1. Type or paste text into the left box, or drop a file onto it.
    2. The 32-character MD5 hash appears on the right. Choose Hex or Base64 under Format, and tick Uppercase if you need capital letters.
    3. To check a file, paste the expected MD5 checksum into Compare with a checksum: a green row means the file matches.
    4. Need other algorithms too? Select them in the bar at the top, such as SHA-256 for a stronger check.

    Examples#

    MD5 of a word

    Input
    hello
    Output
    5d41402abc4b2a76b9719d911017c592

    Always 32 hex characters, whatever the input length.

    The classic test sentence

    Input
    The quick brown fox jumps over the lazy dog
    Output
    9e107d9d372bb6826bd81d3542a419d6

    Add a period at the end and the hash becomes completely different.

    MD5 of an empty string

    Input
    Output
    d41d8cd98f00b204e9800998ecf8427e

    If you see this hash in logs or databases, something hashed an empty value.

    What is MD5?#

    MD5 (Message-Digest Algorithm 5) turns any input into a 128-bit hash, written as 32 hexadecimal characters. It was designed by Ronald Rivest in 1991 and published as RFC 1321. For many years it was the default checksum on the internet, and it is still everywhere: file downloads, databases, caches and legacy systems.

    Is MD5 secure?#

    No, not for security. In 2004, researchers led by Xiaoyun Wang showed how to create two different inputs with the same MD5 hash (a collision). Today this takes seconds on a laptop. In 2012, the Flame malware used an MD5 collision to forge a Microsoft code-signing certificate.

    UseMD5 OK?Use instead
    Detecting accidental file corruptionYesMD5 is fine, SHA-256 is better
    Cache keys, ETags, deduplication of trusted dataYesMD5 or a faster hash such as BLAKE3
    Verifying downloads against tamperingNoSHA-256
    Digital signatures and certificatesNoSHA-256 or SHA-3
    Storing passwordsNeverbcrypt or Argon2

    Can MD5 be decrypted?#

    No. MD5 is a one-way function: it compresses any amount of data into 128 bits, so the original cannot be calculated back. Websites that claim to "decrypt MD5" simply look the hash up in huge tables of words they have hashed in advance. That works for common passwords like 123456, which is exactly why MD5 must never be used for passwords.

    MD5 checksums for files#

    Some software still publishes an MD5 checksum (often in a .md5 file) next to a download. Drop the file into this tool and paste the checksum to compare. On the command line:

    bash
    # Linuxmd5sum file.zip # macOSmd5 file.zip # Windows PowerShellGet-FileHash .\file.zip -Algorithm MD5

    MD5 in code#

    PHP#

    php
    md5('hello');                // "5d41402abc4b2a76b9719d911017c592"md5_file('download.zip');    // hash a file

    Python#

    python
    import hashlib hashlib.md5(b'hello').hexdigest()   # '5d41402abc4b2a76b9719d911017c592'

    Node.js#

    javascript
    import { createHash } from 'node:crypto'; createHash('md5').update('hello').digest('hex'); // "5d41402abc4b2a76b9719d911017c592"

    Browsers do not include MD5 in the Web Crypto API (crypto.subtle), because it is no longer considered secure. This tool uses the audited @noble/hashes library instead.

    Common errors and fixes#

    • My MD5 differs from the command line result

      echo "hello" | md5sum hashes "hello" plus a newline. Use echo -n "hello" | md5sum (or printf) to hash exactly the text.

    • The MD5 checksum of my download does not match

      The file is incomplete or corrupted. Download it again. If a SHA-256 checksum is also published, compare that one too.

    • Different results for text with accents or emoji

      MD5 hashes bytes, not characters. This tool uses UTF-8; another tool may use Latin-1 or UTF-16, which gives different bytes and a different hash.

    Frequently asked questions#

    How long is an MD5 hash?

    128 bits, written as 32 hexadecimal characters (or 24 characters in Base64).

    Can two different files have the same MD5?

    Yes. MD5 collisions can be created on purpose in seconds, so MD5 cannot prove that a file has not been tampered with. It still reliably detects accidental changes.

    Can I reverse an MD5 hash?

    No. MD5 is one-way. Lookup sites only find hashes of common words they stored earlier.

    Should I use MD5 for passwords?

    Never. It is fast and unsalted, so attackers can test billions of guesses per second. Use bcrypt or Argon2.

    Is my file uploaded?

    No. The MD5 is calculated in your browser and the file never leaves your device.

    Your next tool is one search away.

    Free, private developer tools that run in your browser. No signup, nothing uploaded, no waiting.

    Browse all tools

    Tip: press Ctrl D to bookmark dev247.