TC

Base64 Encoder / Decoder — Free Online Tool

Last updated: January 2025

Your text is processed locally — we never store your data. Free forever, no signup.
Type something to see all generated styles

What is Base64 Encoder / Decoder?

Base64 Encoder/Decoder converts text to/from Base64 encoding, with URL-safe Base64 option for API usage.

When to use Base64 Encoder / Decoder?

Use it for encoding API tokens, embedding images in HTML/CSS as data URIs, encoding JSON payloads, and email MIME encoding.

How to use this tool

  1. 1Paste your text or Base64 string
  2. 2Choose 'Encode' or 'Decode'
  3. 3Enable URL-safe option if needed, then copy

Examples

InputOutput
Hello WorldSGVsbG8gV29ybGQ=
SGVsbG8gV29ybGQ=Hello World (decoded)
{"user":"john"}eyJ1c2VyIjoiam9obiJ9
https://example.com/path?a=1&b=2aHR0cHM6Ly9leGFtcGxlLmNvbS9wYXRoP2E9MSZiPTI=
secret API tokenBase64 encoded version

Rules & Behavior

  • Standard Base64 uses +/= characters
  • URL-safe Base64 replaces + with - and / with _
  • Padding (=) removed in URL-safe mode

Related Tools

Frequently Asked Questions

What is Base64 encoding?

Base64 encodes binary data into ASCII text using 64 printable characters (A-Z, a-z, 0-9, +, /). It's used when binary data needs to be stored or transmitted in text-based systems.

When would I use Base64?

Base64 is used for embedding images in HTML/CSS (data URIs), encoding JWT tokens, MIME encoding in email attachments, and passing binary data in JSON or XML.

What is URL-safe Base64?

URL-safe Base64 replaces + with - and / with _ to make the encoded string safe for use in URLs and filenames without percent-encoding.

Is Base64 the same as encryption?

No! Base64 is encoding, not encryption. It's easily reversible by anyone and provides no security. Use it for format compatibility, not for hiding data.

Why does Base64 output end with ==?

The = padding aligns the output to multiples of 4 characters. The number of = characters (0, 1, or 2) depends on the input length.