Base64 Encoder & Decoder

Encode text to Base64 and decode it back — with proper UTF-8 handling (Chinese and emoji won't break) and an URL-safe mode. Everything stays in your browser.

Runs locally in your browser

Input

Output

How to use Base64 Encoder

  1. Paste text into the input box.
  2. Choose Encode or Decode depending on the direction.
  3. Copy the result with one click.

Common use cases

Good to know

What you can do next

FAQ

Is my data uploaded?

No. Encoding is built into your browser — tokens, credentials and payloads stay on your device.

Why do other tools mangle Chinese text?

JavaScript's native btoa() only handles Latin-1. This tool routes through TextEncoder/TextDecoder, so any UTF-8 text — Chinese, emoji, Arabic — round-trips correctly.

When do I need URL-safe Base64?

When the encoded value goes into a URL or filename (JWTs, tokens in links) — standard Base64's + and / characters break URLs, so they're swapped for − and _.

X