Sumplain

Developer

Base64 Encoder and Decoder

Encode text as Base64 or decode Base64 back to text locally.

Quick answer

How does Base64 Encoder and Decoder work?

Encode text as Base64 or decode Base64 back to text locally. The method, assumptions, worked example, and primary references are shown on this page.

Inputs

Text or Base64

Output

Converted text

Your converted text will appear here.

Result

How to read this result

The current result follows the selected fields and the rules explained on this page. It should be interpreted with the stated scope and limits.

Understand this tool

Base64 is an encoding, not protection

What the concept means
Base64 is a binary-to-text encoding that represents arbitrary bytes with a restricted alphabet of printable characters.
Why it exists
It lets binary data travel through systems designed around text, including MIME email bodies and textual protocol fields.
When to use it
Use it when a format explicitly requires Base64; do not use it to hide secrets.
What the result means—and does not mean
Decoding only reverses a representation. Base64 provides no encryption, integrity, authentication, compression, or proof that decoded bytes are safe.

History and standardization

The earliest standardized use of the modern MIME Base64 alphabet can be traced to Privacy-Enhanced Mail work published in 1987. MIME later adopted the encoding for email content, and RFC 4648 documented the common Base64 and Base64URL alphabets. It is more accurate to describe this standards lineage than to name one inventor.

Different systems had earlier radix-64 encodings, so “Base64” is a family name as well as the common RFC 4648 encoding. Protocol rules decide whether padding or line wrapping is required.

How 24 input bits become four characters

The encoder takes three bytes, or 24 bits, splits them into four six-bit groups, and maps each number from 0 to 63 to one alphabet character. Four output characters therefore represent three input bytes, producing roughly a 4:3 size expansion before line breaks or surrounding syntax.

If the final group contains one or two bytes, zero bits complete the last six-bit group and “=” characters commonly mark the missing input bytes. Padding is metadata, not part of the original data. Base64URL replaces “+” and “/” with “-” and “_” so the text is safer in URL and filename contexts.

Key concepts

Key concepts

Base64
The common 64-symbol binary-to-text encoding family.
Binary-to-text encoding
A reversible representation of bytes using text characters.
Base64 alphabet
The 64 symbols assigned to six-bit values.
Six-bit group
A number from 0 to 63 mapped to one Base64 character.
Padding
Trailing “=” markers used to signal an incomplete final three-byte block.
Base64URL
The URL-safe alphabet variant defined by RFC 4648.
MIME
Internet email standards that standardized widespread Base64 use.

Method or process

How the process works

How 24 input bits become four characters

The encoder takes three bytes, or 24 bits, splits them into four six-bit groups, and maps each number from 0 to 63 to one alphabet character. Four output characters therefore represent three input bytes, producing roughly a 4:3 size expansion before line breaks or surrounding syntax.

If the final group contains one or two bytes, zero bits complete the last six-bit group and “=” characters commonly mark the missing input bytes. Padding is metadata, not part of the original data. Base64URL replaces “+” and “/” with “-” and “_” so the text is safer in URL and filename contexts.

Compare the concepts

Related Base64 variants

VariantAlphabet detailTypical context
Standard Base64+ and /General RFC 4648 data
MIME Base64Standard alphabet with MIME line rulesEmail bodies
Base64URL- and _URLs, filenames, JWT segments

Common mistakes

Common mistakes

  • Calling Base64 encryption.
  • Assuming every decoder accepts omitted padding.
  • Encoding visible text without agreeing on its byte encoding.

Edge cases and limits

Edge cases and limits

  • Whitespace acceptance depends on the surrounding protocol.
  • Malformed padding may be rejected.
  • Decoded bytes may not be valid UTF-8 text.

Frequently asked questions

Quick answers about the result and its assumptions.

Is Base64 encryption?

No. It is a reversible text encoding and provides no secrecy.

Is my text uploaded?

No. Encoding and decoding run locally in the browser.

Can I rely on this result without checking it?

Use it as a transparent estimate or transformation, review the stated assumptions, and independently verify any result used for an important decision.

Disclaimer: This tool is for general information only and does not provide financial, medical, legal, tax, or other professional advice.