Base64 Encode and Decode

Type or paste text and the Base64 result appears instantly.

Your text and files never leave your browser — nothing is sent to a server.

How to use

  1. Paste your text and choose Encode or Decode. Text is encoded as UTF-8, so accents, emoji and non-Latin scripts work.
  2. Turn on “URL-safe” for tokens, file names or URLs — + and / become - and _, and the trailing = padding is removed.
  3. Turn on “Wrap lines at 76 characters” when the result goes into an email body or a PEM-style block.
  4. When decoding you can paste standard Base64, URL-safe Base64 or a whole data: URL; line breaks and missing padding are ignored.

FAQ

Is Base64 encryption?

No. Base64 only changes how bytes are written so they can travel through text-only channels. Anyone can decode it, so never use it to hide passwords or secrets.

Why is the Base64 output longer than the input?

Every 3 bytes become 4 characters, so the result is about 33% larger. Non-Latin characters take 2–4 bytes in UTF-8, which makes their output longer still.

What is URL-safe Base64?

It is the Base64url variant from RFC 4648. It replaces + with - and / with _ so the string can sit in a URL or file name without escaping. JSON Web Tokens use it.

Is my text uploaded?

No. Encoding and decoding run entirely in your browser.

Related tools

All tools