Files are read with FileReader in this browser. A 10 MiB client-side limit prevents accidental memory spikes.

🖼️

Click to upload or drag & drop an image

You can also paste an image (Ctrl+V / Cmd+V)

Measured behavior

Base64 overhead is exact, not always “33%”

Padded Base64 output length is 4 × ceil(n / 3) characters for n input bytes. The familiar one-third overhead only becomes a good approximation as the input grows; padding dominates very small inputs.

Committed size cases

InputOutputMeasured overhead
1 byte4 chars+300%
2 bytes4 chars+100%
3 bytes4 chars+33.33%
100 bytes136 chars+36.00%
1,024 bytes1,368 chars+33.59%
10,000 bytes13,336 chars+33.36%

These values come from the committed deterministic run shown in Z Tools Lab; the Lab publishes the runtime and all seven cases.

What this tool does

  • UTF-8 text: text is converted to bytes with TextEncoder before Base64 encoding so non-ASCII characters are handled explicitly.
  • Local files: files up to 10 MiB are read in the browser and can be converted to raw Base64 or a Data URL without a server-side Base64 processor.
  • Reconstruction: valid Base64/Data URLs can be decoded back into a browser Blob and downloaded.
  • Security boundary: Base64 is reversible encoding, not encryption or authentication. Do not treat encoded text as secret.

For the byte-level derivation, padding examples, and Base64URL distinction, read Base64 Size Overhead: the 4/3 Rule or consult RFC 4648.