What Base64 is, and what it is not
Base64 represents arbitrary bytes with 64 printable ASCII characters (A–Z a–z 0–9 + /). Three bytes become four characters, so the data grows by about a third; a trailing = pads the result to a multiple of four characters (RFC 4648).
Base64 is not encryption. There is no key and no secret: anyone can reverse it in seconds. A password or token in Base64 is exactly as exposed as in plain text.
Where admins run into Base64
- HTTP Basic auth:
Authorization: Basiccarriesuser:passwordin Base64 (RFC 7617); the helper above builds the header. - JWT: header and claims are Base64URL-encoded JSON; read them with the JWT decoder.
- SAML: the
SAMLResponseis Base64 (additionally compressed with the redirect binding); the SAML decoder handles that. - Certificates and keys: the body of a PEM file between
BEGINandENDis Base64 of DER data. - Mail (MIME):
Content-Transfer-Encoding: base64with at most 76 characters per line. - Kubernetes secrets: the values under
dataare merely Base64, which protects nothing. On the shell:kubectl get secret NAME -o jsonpath='{.data.KEY}' | base64 -d.
Base64 vs Base64URL
Base64URL (RFC 4648 section 5) replaces + with - and / with _ so the characters are not reinterpreted in URLs and file names. Padding is often left out there, as in JWTs. When decoding, this tool accepts both alphabets, ignores spaces and line breaks and copes with missing padding. When encoding, pick the alphabet with the option.
Common mistakes and questions
- Trailing newline in the plain text:
echo foo | base64also encodes the newline (Zm9vCg==instead ofZm9v). Useecho -norprintf. - Wrong character set: “ä” is
w6Q=in UTF-8 but5A==in Latin-1. This tool uses UTF-8. - Encoded twice: if the decoded result again looks like Base64 (often starting
ZX…oreyJ…), it was encoded twice. - Wrong length: a remainder of 1 when dividing by 4 means something is missing; missing padding, by contrast, is usually harmless.
- Line breaks from mail or PEM do not matter here; with
base64 -don the shell they may need-iortr -d '\n', depending on the version. - Can I paste passwords here? Processing happens locally in your browser and no network request is made. Still, only type real credentials on devices you trust.
Privacy
Runs entirely in your browser; nothing is sent or stored.