DevToolbox

Base64 Encoder / Decoder

Encode and decode Base64 text with full UTF-8 support.

Processed locally in your browser

Text / Base64 Input

Encoded / Decoded Output

What is the Base64 Encoder / Decoder?

The Base64 Encoder / Decoder converts text to Base64 and back, with full UTF-8 support — including emoji and non-Latin scripts that naive implementations mangle. Base64 encodes binary data as a safe subset of ASCII characters, which is why it appears everywhere: HTTP basic auth headers, data URLs, JWT segments, email attachments, and API payloads.

The decoder accepts both standard Base64 (+ and /) and the URL-safe variant (- and _), tolerates missing padding, and reports a clear error when the input isn't valid Base64 or doesn't decode to valid UTF-8 text.

How to use the Base64 Encoder / Decoder

  1. Type or paste text into the input panel.
  2. Click Encode to produce Base64, or Decode to convert Base64 back to text.
  3. Use Swap to move the output into the input for chained conversions.
  4. Copy the result to your clipboard.

Examples

Encode

Hello, world!  →  SGVsbG8sIHdvcmxkIQ==

UTF-8 round trip

héllo → aMOpbGxv → héllo

Multi-byte characters survive the round trip because encoding is UTF-8 aware.

Frequently asked questions

Is Base64 encryption?

No. Base64 is an encoding, not encryption — anyone can decode it. Never use Base64 to protect secrets; it only makes binary data safe to transmit as text.

Why does my Base64 fail to decode?

Common causes are truncated strings, characters outside the Base64 alphabet, or data that decodes to binary rather than UTF-8 text. The error message distinguishes these cases.

Does this support URL-safe Base64?

Yes. The decoder automatically accepts - and _ in place of + and /, and handles missing = padding, so JWT segments decode without preprocessing.