Base64 Encode / Decode

Encode or decode Base64 text and data URIs.

Convert UTF-8 text. Decode also accepts wrapped Base64 and complete Base64 data URIs.

Free online Base64 encoder and decoder

Convert text to Base64 or decode Base64 back to plain text instantly. This Base64 converter is fully UTF-8 safe, so emoji, accented characters, and any other Unicode encode and decode without corruption. It is perfect for building text data URIs, debugging API payloads, and decoding JSON Web Token segments in Base64url mode. Binary payloads that are not valid UTF-8 are reported clearly. Everything runs live in your browser as you type.

How to encode or decode Base64

  1. Choose Encode to convert text to Base64, or Decode to turn Base64 back into text.
  2. Select Standard Base64 or Base64url, then type or paste your content, or load an example.
  3. Read the converted result in the output box — it updates automatically.
  4. Use Swap to move the result into the input and flip the mode for a quick round trip.
  5. Click Copy result to copy the output, or Clear to start over.

Common uses for Base64

Developers reach for Base64 whenever binary data needs to survive a text-only transport. It powers data: URIs that inline images and fonts, encodes attachments in email, and packages credentials in HTTP headers. When decoding text, this tool ignores spaces and line breaks in wrapped MIME blocks and accepts complete Base64 data URIs. Select Base64url for URL-safe strings that use - and _; its encoded output omits padding. Decoding a JWT segment does not verify its signature. If you are cleaning up API requests, you may also want the URL encoder / decoder for percent-encoded query strings, or the JSON formatter to pretty-print a decoded payload.

Private and secure by design

Base64 is an encoding, not encryption — it hides nothing, since anyone can decode it. Because this converter runs entirely client-side, your data is never uploaded, making it safe to work with sensitive strings. For real data integrity or fingerprinting, generate a checksum with the hash generator instead.

Frequently asked questions

What is Base64 encoding?

Base64 is a way of representing binary or text data using only 64 printable ASCII characters (A–Z, a–z, 0–9, + and /). It is commonly used to embed images in HTML/CSS, send data in JSON or URLs, encode email attachments, and store binary data in text-only systems. Encoding makes data safe to transmit, but it is not encryption — anyone can decode it.

How do I encode text to Base64?

Set the tool to Encode, then type or paste your text into the input box. The Base64 output appears instantly in the box below. Click Copy to grab the result. Encoding is fully Unicode-safe, so emoji, accented letters, and other UTF-8 characters convert correctly.

How do I decode Base64 back to text?

Switch to Decode mode, choose Standard Base64 or Base64url, then paste the encoded text. Spaces and line breaks are ignored. Invalid Base64 or bytes that are not valid UTF-8 show an inline error instead of a corrupted result.

Does this tool handle data URIs?

Yes. Paste a complete Base64 data URI such as data:text/plain;base64,SGVsbG8= or only its payload. Base64 data URIs use the standard alphabet. This tool decodes UTF-8 text; images and other binary files are not rendered as text.

Is my data sent to a server?

No. All encoding and decoding happens locally in your browser with JavaScript. Nothing you type is uploaded, logged, or stored, so it is safe to convert private or sensitive strings.

Is Base64 the same as encryption?

No. Base64 is an encoding, not encryption — it provides no secrecy because anyone can reverse it. If you need to protect data, use proper encryption or hashing. For fingerprinting or checksums, try a hash instead of Base64.