Online MD5 hash

MD5 maps UTF-8 text to a 128-bit digest, shown as 32 lowercase hex characters or the same 16 bytes in Base64. The same bytes always yield the same line; there is no salt and no key. MD5 is fast but not collision-resistant, so it must not store passwords. Use the SHA hash tool for SHA-256 and siblings on new work, and bcrypt, PBKDF2, or Argon2 when the job is login storage.

What thirty-two hex characters say about the UTF-8 bytes you hashed

MD5 reads the UTF-8 bytes of the text and writes a 128-bit digest. On this page that digest is shown as thirty-two lowercase hexadecimal characters with no spaces and no 0x prefix. Sixteen bytes sit behind those digits. An empty field is zero bytes and still prints a full thirty-two character line, not a blank output. The three letters abc are three bytes with a well-known test vector you can load with the example buttons. The same bytes and the same algorithm always land on the same line, because MD5 does not mix in a salt or a key.

Hex is one spelling of the sixteen digest bytes. Sixteen raw bytes can also be written in Base64 for shorter wire forms, but that alphabet is not the thirty-two hex characters printed here. Changing only the case of hex letters does not change the bytes. Adding a newline after abc adds the byte 0A and changes the whole digest. The function hashes bytes, not the shape on the screen.

MD5 is fast and collision weaknesses are well known, so it does not belong in new password tables or anywhere two different messages must never share a digest. Modern work belongs on the hash digest page for SHA-256 and siblings, on HMAC when a key is required, and on slow stores such as bcrypt, PBKDF2, and Argon2 for human-chosen secrets. Reading the bytes behind hex is what hex encode and decode covers.

How bit length, UTF-8 bytes, and the hex line relate before you compare

Why MD5 always writes exactly thirty-two lowercase hexadecimal characters

  1. The digest is 128 bits. Two hex digits are one byte, so the printed form is sixteen bytes and thirty-two characters.
  2. This page uses lowercase a through f. Uppercase spells the same sixteen bytes and is equally valid for parsers that accept both.
  3. A string shorter or longer than thirty-two hex digits is not a complete MD5 digest in this notation.

Why empty input and the three letters abc still produce predictable digests

  1. Zero bytes still yield a full thirty-two character digest, not an empty output field.
  2. The three-byte word abc has a standard MD5 test vector in docs and unit tests; the abc example loads it here.
  3. Typing the ten hex characters 616263 hashes those ten ASCII bytes, not the three-byte word abc inside quotes.

Why hex on the page names the same sixteen bytes as a Base64 wire form

  1. MD5 output is always sixteen raw bytes. Hex expands each byte to two nibbles so every value is visible.
  2. Base64 packs the same sixteen bytes with a sixty-four character alphabet and padding. Length and spelling differ; the byte string does not.
  3. APIs sometimes return Base64 where logs show hex. Converting between spellings must decode to identical sixteen bytes before compare.

Why MD5 must not stand in for password storage or collision-free security

  1. The same password always yields the same MD5 with no salt, so rainbow tables and bulk guessing stay practical.
  2. Published collision techniques mean two different messages can share an MD5 in adversarial settings. That breaks naive integrity assumptions.
  3. Password rows want a slow hash, a per-user salt, and often memory cost. bcrypt, PBKDF2, and Argon2 are built for that job.

Where the copied digest and the bytes you typed quietly disagree

A test that expected the published MD5 of abc

The UTF-8 bytes of abc define a standard MD5 test vector you can confirm with the example control. Dropping a letter, hashing ABC instead, or switching to SHA-256 on the hash digest page produces a different string and often a different length. MD5 stays at thirty-two hex characters. None of those algorithms adds a key; a keyed check is HMAC.

A cache header that showed Base64 while the doc listed hex

Both forms name sixteen digest bytes. Hex is thirty-two characters from 0-9 and a-f. Base64 is shorter and uses a different alphabet with optional padding. Pasting one into a field that expects the other fails comparison even when the underlying hash is correct. hex encode and decode walks the byte view that both spellings share.

A login table that still stored bare MD5 beside a modern column

MD5 of a password is one fast step with no embedded salt. Identical passwords collide in the table, and attackers can precompute millions of guesses. Moving forward means rehashing at login with bcrypt or PBKDF2 or Argon2, or running a staged migration. MD5 here only explains the digest shape, not a policy for new credentials.

Common questions

How long is an MD5 hash in hex?
MD5 is 128 bits, which is sixteen bytes, which is thirty-two hexadecimal characters. Each byte is two digits from 0 through 9 and a through f. This page prints lowercase with no spaces and no 0x prefix. An uppercase copy names the same bytes. A line of a different length is incomplete, includes separators that must be removed, or is not MD5 at all.
What is the MD5 of an empty string?
An empty message is zero UTF-8 bytes, and it still has a digest. On this page the output is thirty-two lowercase hex characters, not a blank field and not an error. Clear the input to see that line. A single space is one byte with value 20, and that is a different message from the empty one with a different digest.
What is the MD5 of abc?
The three letters abc are the UTF-8 bytes 61 62 63. Click the abc example to print the standard thirty-two character MD5 for that word. abc with different casing is different bytes and a different digest. Pasting the hex text 616263 into the input hashes ten byte values, not the three-letter word abc as typed in normal text.
Is MD5 the same as SHA-256 on the hash digest page?
No. Both read UTF-8 bytes and print hex, but MD5 is 128 bits and thirty-two characters, while SHA-256 is 256 bits and sixty-four characters. The same abc bytes on hash digest under SHA-256 produce a sixty-four character line that does not match MD5 length or value. Pick the algorithm the spec names before you compare digests.
Should I store passwords as MD5?
No for new designs. MD5 is fast, unsalted, and vulnerable to collision research in security-sensitive designs. Identical passwords produce identical digests, which feeds rainbow tables. Use a slow password hash with salt, such as bcrypt, iterated PBKDF2, or memory-hard Argon2. MD5 may still appear when reading legacy data, not when choosing how to store new secrets.
What is the difference between MD5 hex and MD5 Base64?
Both represent the same sixteen-byte digest. Hex uses thirty-two digits from the sixteen-symbol alphabet 0-9 and a-f. Base64 uses a sixty-four character alphabet and often ends with padding equals signs, so the string is shorter on the wire. Converting for compare means decoding to bytes, not sorting the two strings as plain text. hex encode and decode shows how hex maps to raw bytes.
How is MD5 different from HMAC-MD5?
MD5 alone hashes only the message bytes. HMAC mixes a secret key into the construction first, so two parties with different keys get different tags even when the message matches. Integrity checks that require a shared secret belong on HMAC. A bare MD5 can show that one specific byte string was hashed, but it cannot prove who knew a key.
Can MD5 be reversed to recover the original text?
No. The digest is fixed length and many messages map into the same 128 bits in theory. Nothing in the thirty-two hex characters records message length or a path backward. Matching MD5 means the UTF-8 bytes were the same under this algorithm. It does not reveal the text, and it does not by itself prove integrity when an attacker can choose another message with the same digest.
Why does my MD5 change when I add a trailing newline?
A newline is a byte. In UTF-8 that byte is 0A. abc without a newline is three bytes; abc followed by a newline is four bytes and a completely different digest. File checksum tools often include the final newline. A single-line text field does not unless the newline was typed. The visible word can match while the byte strings do not.