Photo File Size Estimator screenshot

Photo File Size Estimator

Work out the bytes an image occupies at a stated bit depth and compression from width in pixels, height in pixels, bits per channel, channels per pixel, compression ratio. Bytes = width × height × bits × channels ÷ 8 ÷ compression ratio, and the page prints the substitution so the result can be checked by hand.

Privacy First
0 Runs
Updated 2026-11-22
Runs in your browser
No sign-up, no upload
Formula printed with the answer

Photo File Size Estimator

Work out the bytes an image occupies at a stated bit depth and compression from width in pixels, height in pixels, bits per channel, channels per pixel, compression ratio. Bytes = width × height × bits × channels ÷ 8 ÷ compression ratio, and the page prints the substitution so the result can be checked by hand.

How this page computes

Bytes = width × height × bits × channels ÷ 8 ÷ compression ratio

A raw file stores one 14-bit sample per photosite and rebuilds the other colours, so the channel count is 1, not 3. Entering 3 for a Bayer raw overstates the file by a factor of three.

The compression ratio is an input because it depends on the image: a flat sky compresses far more than foliage at the same quality setting.

The calculation runs entirely in this browser tab; nothing is uploaded.

Photo File Size Estimator computes the bytes an image occupies at a stated bit depth and compression. Bytes = width × height × bits × channels ÷ 8 ÷ compression ratio. The page prints the rule, the numbers substituted into it and the result, so the arithmetic can be checked by hand.

A raw file stores one 14-bit sample per photosite and rebuilds the other colours, so the channel count is 1, not 3. Entering 3 for a Bayer raw overstates the file by a factor of three. Pressed with width in pixels 6000, height in pixels 4000, bits per channel 14, channels per pixel 1, compression ratio 1, it answers: Estimated file size = 40.0543 MB

How to use Photo File Size Estimator

Enter width in pixels 6000, height in pixels 4000, bits per channel 14, channels per pixel 1, compression ratio 1, then press Run: the page evaluates the bytes an image occupies at a stated bit depth and compression and prints every line of the working. Typed input is read exactly as written, and a blank field is refused with its name.

Read the first line as the answer and the lines below it as the substitution. If a value is out of range the page refuses it by field and reason instead of printing a number.

With width in pixels 6000, height in pixels 4000, bits per channel 14, channels per pixel 1, compression ratio 1, the answer is Estimated file size = 40.0543 MB.

Bayer is one channel per photosite

A raw file stores one 14-bit sample per photosite and rebuilds the other colours, so the channel count is 1, not 3. Entering 3 for a Bayer raw overstates the file by a factor of three.

The compression ratio is an input because it depends on the image: a flat sky compresses far more than foliage at the same quality setting.

What to Expect

Best for

  • Working out the bytes an image occupies at a stated bit depth and compression without a spreadsheet
  • Checking a figure someone else quoted
  • Seeing the formula behind an answer

Not ideal for

  • Zero pixels, bits, channels or compression ratio is refused.
  • A quantity the page cannot compute, which it refuses instead of estimating
  • Rounding an answer that has an exact form

What this tool keeps

  • Bytes = width × height × bits × channels ÷ 8 ÷ compression ratio
  • Every input exactly as typed

What may need cleanup

  • Nothing: the printed answer is the final output
  • A unit conversion, if the inputs were entered in different units

Common errors

  • Zero pixels, bits, channels or compression ratio is refused.
  • An empty field is refused with the field's name

Example use cases

  • Work out the bytes an image occupies at a stated bit depth and compression for one set of inputs
  • Check the result against the formula by hand
  • See which input the answer is most sensitive to

Sample input

Photo File Size Estimator: width in pixels 6000, height in pixels 4000, bits per channel 14, channels per pixel 1, compression ratio 1

Sample output

Estimated file size = 40.0543 MB — Raw bytes = width × height × bits × channels ÷ 8 = 6000 × 4000 × 14 × 1 ÷ 8 = 42000000

Who this is for

  • Students checking a formula
  • Anyone who needs the number and the working

Frequently asked questions

What formula does this page use?

Bytes = width × height × bits × channels ÷ 8 ÷ compression ratio. The page prints the substitution as well, so the answer can be checked against the rule.

What does Photo File Size Estimator refuse?

Zero pixels, bits, channels or compression ratio is refused.

What does the default example give?

Width in pixels 6000, height in pixels 4000, bits per channel 14, channels per pixel 1, compression ratio 1 gives Estimated file size = 40.0543 MB. Every line below that restates the same arithmetic.

Developer program

Build custom tools for your store

Join the SDK program to create useful ecommerce utilities for your store.