Base64 Encoder / Decoder
Encode text to Base64 or decode it back, with URL-safe alphabet, padding and line-wrap options.
Standard or URL-safe, with or without padding. Whitespace and line breaks are ignored.
Useful when the decoded bytes aren't valid UTF-8 text.
Byte length
0
Base64 length
0
About Base64
Base64 turns arbitrary bytes into ASCII text by mapping every 3 bytes onto 4 printable characters, so binary data survives transports that only allow text (email, JSON, URLs, data URIs).
- Standard alphabet uses
+and/; the URL-safe variant swaps them for-and_so the result is safe in URLs and file names. - Padding (
=) fills the last group to 4 chars. Many parsers accept unpadded input, so it can be dropped to save bytes. - Line wrap at 64 or 76 columns matches MIME and PEM formats.
Everything runs locally in your browser — nothing is uploaded. For hex and raw byte views alongside Base64, see the Hex / Bytes / Base64 tool.