{}DevStringToolsAll tools

Base64 Encode / Decode

Encode plain text to Base64 or decode Base64 strings back to UTF-8 text. Useful for embedding binary-ish data in URLs, JSON, and config files.

UTF-8 safe: works with emoji & non-Latin text
13 chars

How Base64 Encode / Decode works

Base64 Encode / Decode converts text to and from the Base64 alphabet (A-Z, a-z, 0-9, +, /, with = padding). Encoding first converts your string to UTF-8 bytes — so emoji, CJK characters, and accented letters all round-trip correctly — then Base64-encodes those bytes. Decoding reverses the process and validates padding and alphabet characters.

How to use

Switch the mode (Encode or Decode), paste your input, and copy the output. Encoding preserves line breaks in your source; decoding outputs UTF-8 text.

Frequently asked questions

Does the Base64 tool handle non-ASCII characters?

Yes. The encoder treats input as UTF-8 text, so emoji, accented letters, CJK characters, and symbols like € all encode and decode correctly. The underlying byte stream is preserved.

Why does my Base64 output have "=" at the end?

Trailing "=" is padding that marks the input length up to a multiple of 4 bytes. Valid Base64 requires it; some decoders tolerate missing padding, but it is best to keep it.

Is Base64 encryption?

No. Base64 is an encoding, not encryption — it is trivially reversible by anyone who knows the alphabet. Never use Base64 as a security mechanism for secrets; use a real cipher.

Can I encode binary files with this tool?

Not directly — the input is text. For binary-to-Base64, encode your file as a data URL, run a script with `base64` (CLI), or use a dedicated file utility.

My decoded output has weird characters — what went wrong?

Most often the input was not valid Base64 (wrong alphabet, missing padding, or stray whitespace). The tool surfaces the decode error in the output; trim spaces and verify the source.