NumbarnNumbarn

Base64 Encode / Decode

Adjust the inputs below. Results update as you type.

How it works

Base64 represents binary data using 64 printable ASCII characters (A–Z, a–z, 0–9, +, /). Every 3 bytes of input become 4 Base64 characters, expanding data by 33%. Padding '=' characters align output to multiples of 4. URL-safe Base64 replaces + with − and / with _ to avoid URL encoding issues. Common uses: embedding images in HTML/CSS, encoding email attachments (MIME), and transmitting binary data in JSON APIs.

Input guidance

  • Confirm date/time/unit settings before comparing outputs.
  • If a task has optional fields, run both with and without them to understand impact.
  • Save scenario variants when making practical decisions.

The formula

Base64 maps every 3 bytes of binary to 4 printable ASCII characters from a 64-symbol set, expanding size by about 33%. Padding '=' aligns output to multiples of 4.

Worked example

The text 'Hi' (2 bytes) encodes to 'SGk=' — four Base64 characters, with one padding character.

More examples to test

  • Quick-pass example: run default assumptions for a first estimate.
  • Refined example: update one assumption at a time to isolate impact.

How to interpret results

Use outputs as operational estimates and pair them with local constraints, business rules, or provider requirements.

When this can be inaccurate

Utilities can miss local policy details, special-case rules, and environment-specific constraints.

Change history

  • July 2026: Quality-reviewed for publication with formula checks and explanatory copy updates.

Site-wide corrections also appear on the corrections log.

Sponsored

Find productivity tools for everyday workflows

General recommendation, not professional advice.

Frequently asked questions

What is Base64 used for?+

Safely embedding binary data in text contexts: email attachments (MIME), images in HTML/CSS, and binary payloads inside JSON or URLs.

Is Base64 encryption?+

No. It is encoding, not encryption — anyone can decode it. It protects data integrity in transit, not confidentiality.

Why does Base64 make data bigger?+

It represents 3 bytes with 4 characters, a 33% increase, the cost of making binary safe for text-only channels.

Why are outputs slightly different from another tool?+

Different tools can use different rounding rules, default assumptions, and treatment of edge cases.

How can I improve estimate reliability?+

Use verified inputs from real records and re-run calculations after major assumption changes.

Related calculators