Base64 Encode / Decode

Convert text to Base64 and Base64 back to text instantly — free, with full Unicode and emoji support. Everything runs locally in your browser; nothing is ever uploaded.

URL-safe and wrapping apply when encoding; the decoder accepts both alphabets and ignores line breaks automatically.

How to use the Base64 Encode / Decode tool

  1. Pick a mode. Choose Encode to turn plain text into Base64, or Decode to turn a Base64 string back into readable text.
  2. Paste your input. The result appears instantly as you type. Enable the URL-safe option for JWT-style output, or 76-character wrapping for MIME email bodies.
  3. Copy or download. Grab the result with the copy button, download it as a file, or hit Swap to feed the output back in and convert the other way.

About this tool

Base64 is a binary-to-text encoding that represents any sequence of bytes using 64 safe ASCII characters (A–Z, a–z, 0–9, + and /). It is everywhere in software development: data URIs for inline images, Basic authentication headers, email attachments, JSON Web Tokens and API payloads that must survive text-only channels. This online Base64 encoder and decoder converts in both directions instantly, and because text is first encoded as UTF-8 bytes, accented characters, Chinese text and emoji round-trip perfectly — something the browser's raw btoa() function cannot do on its own.

The decoder is forgiving by design: it accepts both the standard and the URL-safe alphabet, ignores whitespace and line breaks, and repairs missing = padding before decoding. All processing happens locally in your browser, so credentials, tokens and private messages never leave your device. Working with JWTs specifically? Our JWT Decoder splits and decodes all three token parts for you.

Frequently asked questions

Is Base64 a form of encryption?

No. Base64 is an encoding, not encryption — anyone can decode it instantly, with no key required. Use it to transport data safely through text-only systems, never to protect secrets.

Does this tool support Unicode and emoji?

Yes. Text is converted to UTF-8 bytes before encoding, so any character — é, 中文, العربية or 😀 — encodes and decodes correctly. When decoding, the tool also warns you if the bytes are not valid UTF-8 text.

What is URL-safe Base64?

A variant (RFC 4648 §5) that replaces + with - and / with _ and usually drops the = padding, so the string can be used in URLs, filenames and JWTs without percent-encoding. Enable the URL-safe checkbox to produce it; the decoder accepts both variants automatically.

Why is Base64 output longer than the input?

Base64 stores 3 bytes of data in 4 characters, so output is about 33% larger than the input bytes. That overhead is the price of using only safe printable ASCII characters.