Base64 Encode/Decode

Encode Unicode text as Base64 or decode Base64 safely and privately in your browser.

Base64 Encode/Decode

Encode Unicode text to Base64 or decode Base64 back to text.

0 lines · 0 characters

All processing happens locally in your browser.

How It Works & Methodology

Base64 is a group of binary-to-text encoding schemes defined in RFC 4648. It represents binary sequences in an ASCII string format by translating 8-bit bytes into a radix-64 representation.

Base64 is designed to transport binary data (such as images, file attachments, and encryption keys) across channels that only reliably handle plain text without corrupting data during transit.

How Base64 Encoding Works Step-by-Step

1. Every 3 bytes (24 bits) of raw data are divided into 4 chunks of 6 bits each.

2. Each 6-bit chunk has a numeric value ranging from 0 to 63, which indexes into the standard 64-character alphabet:

• Indices 0–25: A–Z

• Indices 26–51: a–z

• Indices 52–61: 0–9

• Index 62: + (plus)

• Index 63: / (slash)

• Padding: = (equal sign used when input is not a multiple of 3 bytes)

Because 3 bytes of raw binary data turn into 4 ASCII text characters, Base64 encoding increases data overhead size by exactly 33.3% (or 4/3).

Common Use Cases in Modern Software

  • Data URIs (Inline Assets): Embedding small icons, SVGs, or PNGs directly inside HTML <img src="data:image/png;base64,..."> or CSS files.
  • API Payloads: Passing binary payloads (such as PDF files or cryptographic keys) securely within JSON and XML structures.
  • Email Attachments (MIME): Standard protocol encoding to ensure binary files survive email transfer agents.

Frequently Asked Questions

How to use Base64 Encode/Decode

  1. 1

    Paste Unicode text or a Base64 value.

  2. 2

    Choose Encode or Decode.

  3. 3

    Process the value and copy or download the result.

Why use this tool?

Unicode-safe

Text is converted through UTF-8 so international characters are handled correctly.

Two-way conversion

Use one interface for both Base64 encoding and decoding.

Local operation

The input remains in the browser and is not logged or uploaded.

Frequently asked questions

Is Base64 encryption?

No. Base64 is a reversible text encoding and does not protect confidential information.

Can it encode emoji and accented text?

Yes. The tool encodes text as UTF-8 before converting it to Base64.

Related tools

Everyday Utilities