Skip to content
ENExplore Calculators

Base Encoding Size Calculator

Work out base encoding size instantly with clear inputs, formula shown and shareable results.

About Base Encoding Size Calculator

Base encodings trade size for a restricted character set. Base64 packs three bytes into four characters for a 33 percent increase, Base32 uses five bytes per eight characters for 60 percent, and hex doubles the size. Line wrapping adds two bytes per break in MIME contexts, which is why an email attachment is noticeably larger than the file it carries.

Formula

Encoded size

Base64: ceil(bytes/3) x 4; Base32: ceil(bytes/5) x 8; hex: bytes x 2; Base58: about bytes x 1.365; add 2 bytes per wrapped line

Worked example

With the default values below, Base Encoding Size Calculator returns Encoded size including line breaks of 1.37 MiB. Change any input above and every figure here is recalculated in your browser.

Inputs used

Input sizeminimum 1 bytes
1,048,576 bytes
Encodingone of Base64 (4 chars per 3 bytes), Base32 (8 chars per 5 bytes), Base16 / hex (2 chars per byte), Base58 (Bitcoin alphabet)
Base64 (4 chars per 3 bytes)
Wrap lines ataccepts 0–998 chars
76 chars

Results

Encoded size including line breaks
1.37 MiB
Encoded characters
1,398,104
Size increase
36.84%
Expansion factor
1.3684 x

Step by step

  1. 1Values used
  2. 2Encoded size
  3. 3Encoded size including line breaks= 1,434,896
  4. 4Encoded characters= 1,398,104
  5. 5Size increase= 36.84
  6. 6Expansion factor= 1.3684 x

Assumptions and limits

  • The result is derived only from the 3 inputs listed above. Anything not among them is not part of the calculation.
  • In particular, this calculator does not take inflation, tax, fees or charges or compounding frequency into account.
  • Figures are rounded for display to 4 decimal places, so totals built from several rounded parts can differ slightly from the unrounded arithmetic.

How these calculators are built and tested is described on the Methodology page. If a figure looks wrong, please report it.

Frequently Asked Questions

Why use Base32 when Base64 is smaller?

Base32 avoids case sensitivity and visually similar characters, so it survives being typed, spoken or embedded in DNS labels and case-insensitive filenames.

Is Base64 a form of encryption?

No. It is a reversible encoding with no key. Anything Base64-encoded is plainly readable to anyone who decodes it.

Base Encoding Size Calculator | Calcrivo