Base64 Encoder & Decoder

Encode and decode Base64 for text (full UTF-8 / emoji support) and files. Supports URL-safe Base64, MIME line wrapping, Data URIs and image preview.

Mode: Encode

Input

0 characters · 0 bytes

Tip: press Ctrl+Enter to run the current mode.

Output

0 characters · 0 bytes

How to Use the Base64 Converter

Text

  1. Type or paste text into the Input box
  2. Click Encode or Decode (with Live mode the result updates as you type)
  3. Enable URL-safe for base64url (- and _, no = padding), e.g. for JWTs and URLs
  4. Enable Wrap lines at 76 for MIME / e-mail compatible output
  5. Use Swap to feed the result back as input and reverse the direction

Files

  1. Switch to the File tab
  2. Drop a file or click to choose one — get raw Base64 and a ready-to-use Data URI
  3. To reverse, paste Base64 or a Data URI on the right and click Decode
  4. The file type is detected from its magic bytes; images are previewed and any file can be downloaded

What is Base64?

Base64 is a binary-to-text encoding that represents any data using 64 printable ASCII characters (A–Z, a–z, 0–9, +, /). It is used to embed binary data in JSON, XML, HTML, CSS, e-mail (MIME) and URLs. Encoded output is about 33% larger than the original. Text is converted to UTF-8 bytes first, so accents, CJK characters and emoji round-trip correctly. Base64 is an encoding, not encryption.

Privacy & Security: All encoding and decoding — including files — happens entirely in your browser. No data is uploaded to any server.

Send Feedback or Request