Encoding

Base64 Encoder & Decoder

Encode text to Base64 or the URL-safe Base64URL variant, and decode Base64 back to UTF-8, entirely in your browser. Base64 is an encoding, not encryption — it does not protect secrets.

Free to use · Runs in your browser · No account required

Processed locally in your browser

Nothing you enter here is uploaded, transmitted to a server, or stored by this tool. Base64 is reversible by anyone — never rely on it to protect a secret.

Runs entirely in your browser — nothing is sent to a server

0 bytes (UTF-8) in the input above.

Output

No output yet

Enter text or Base64 above to see the result here.

Base64 is an encoding, not encryption — anyone can decode it instantly. Never rely on it to protect a secret.

How to use this tool

  1. 1Choose Encode or Decode, then paste text or Base64 into the panel.
  2. 2Toggle Base64URL if the target system needs the URL-safe alphabet (used by JWTs, for example).
  3. 3Use Swap to feed the output straight back in as new input — handy for round-trip checks.
  4. 4Copy or download the result. Byte counts are shown so you can sanity-check size changes.

Base64 is encoding, not encryption

Base64 represents arbitrary bytes using 64 printable ASCII characters, which is why it shows up wherever binary data needs to travel through text-only channels — email attachments, data URIs, and the header/payload segments of a JWT. It expands data by roughly 33% and adds no confidentiality: decoding requires no key, only the reverse lookup table.

Base64URL swaps + and / for - and _, and typically omits the trailing = padding, so the result is safe to embed directly in a URL or filename without further escaping.

Frequently asked questions

Is Base64 encryption?

No. Base64 is a reversible encoding scheme with no key. Anyone can decode it instantly — it does not provide confidentiality.

What's the difference between Base64 and Base64URL?

Base64URL replaces the `+` and `/` characters with `-` and `_` and typically omits padding `=` characters, so the result is safe to use inside URLs and filenames without additional encoding.

Why did decoding fail with an error?

The input contains characters outside the Base64 alphabet, or its length isn't a valid multiple for the padding scheme selected.

Planned — not yet published

  • Planned
    Base64 is not encryption: what it actually protects (nothing)A myth-busting walkthrough with decode-in-one-line proof.
  • Planned
    Base64 vs Base64URL: why JWTs use a different alphabetPadding, `+`/`/` vs `-`/`_`, and URL-safety tradeoffs.
  • Planned
    Encoding binary files as Base64 without blowing up memoryStreaming approaches in Node.js for large attachments.