Skip to content

Image Resolution Calculator: Megapixels, DPI and Print Size

Megapixels, aspect ratio, maximum print size at 300 DPI and file size from pixel dimensions, or the pixels a print needs.

Your details

Unit system
I know
px
px

300 DPI for photo prints and magazines, 240 for good home prints, 150 for posters seen from a distance.

DPI
Colour channels
Bit depth per channel

Results update as you type

Megapixels

24 MP

Total pixels
24,000,000
Aspect ratio
3:2 (1.5:1)
Print size at this resolution (cm)
50.8 × 33.87 cm
Print size at this resolution (in)
20 × 13.33 in
Uncompressed file size
72 MB
Same in binary units
68.66 MiB

File sizes are for an uncompressed bitmap (TIFF without compression, BMP, raw pixel buffer). JPEG, HEIC or PNG files are usually much smaller.

Step-by-step solution
  1. 6,000 × 4,000 = 24,000,000 px = 24 MP
  2. 6,000 ÷ 300 = 20 in × 2.54 = 50.8 cm
  3. 24,000,000 × 3 × 8 ÷ 8 = 72,000,000 B

Maximum print size at common resolutions

A digital image is a grid of pixels, and its resolution decides two practical things: how large you can print it before it looks soft, and how heavy the file is. This calculator answers both questions from the pixel dimensions, and it also works the other way round, telling you how many pixels a given print size needs.

Enter the width and height in pixels to get the number of megapixels, the aspect ratio (3:2, 4:3, 16:9…), the print size at the resolution you choose, and a table of maximum print sizes at 300, 240 and 150 DPI in centimetres and inches. Switch to print size to enter, say, a 30 × 20 cm photo or an A4 page and see the pixel dimensions required.

The file size shown is the uncompressed size: width × height × number of channels × bit depth. It is the memory an editor needs to hold the image and the size of an uncompressed TIFF, and a useful upper bound before JPEG or HEIC compression.

How to use this calculator

  1. Choose whether you know the pixel size or the print size.
  2. Enter the width and height in pixels, or the print dimensions in cm, mm or inches.
  3. Set the print resolution in DPI (pixels per inch): 300 is the usual photo standard.
  4. Pick the colour channels (RGB, RGBA with transparency, or grayscale) and the bit depth (8 or 16 bits per channel) for the file size.
  5. Read the megapixels or the pixels needed, the aspect ratio, the print size and the file size. The table compares 300, 240 and 150 DPI.

The formula

With a width ww and height hh in pixels, and a print resolution rr in pixels per inch:

MP=w×h106print width (in)=wrprint width (cm)=wr×2.54\text{MP} = \frac{w \times h}{10^6} \qquad \text{print width (in)} = \frac{w}{r} \qquad \text{print width (cm)} = \frac{w}{r} \times 2.54

The other way round, a print of width LL cm at rr DPI needs w=L2.54×rw = \frac{L}{2.54} \times r pixels, rounded to the nearest pixel. The inch is exactly 2.54 cm.

The uncompressed size, with cc channels (3 for RGB, 4 for RGBA, 1 for grayscale) and bb bits per channel, is

S=w×h×c×b8 bytesS = \frac{w \times h \times c \times b}{8} \text{ bytes}

Here 1 MB = 1,000,000 bytes and 1 MiB = 1,048,576 bytes, the binary unit many operating systems still label “MB”. The aspect ratio is w:hw:h divided by their greatest common divisor.

Worked example

From pixels. A 24-megapixel camera produces images of 6000 × 4000 pixels.

  • Megapixels: 6000×4000=24 000 0006000 \times 4000 = 24\,000\,000 pixels, so 24 MP, in a 3:2 ratio.
  • At 300 DPI: 6000/300=206000 / 300 = 20 in by 4000/300=13.334000 / 300 = 13.33 in, that is 50.8 × 33.87 cm.
  • At 240 DPI the same file prints at 63.5 × 42.33 cm, and at 150 DPI at 101.6 × 67.73 cm.
  • Uncompressed 8-bit RGB: 24 000 000×3=72 000 00024\,000\,000 \times 3 = 72\,000\,000 bytes = 72 MB (68.66 MiB). In 16-bit it doubles to 144 MB.

From a print size. A 30 × 20 cm print at 300 DPI needs 3,543 × 2,362 pixels (8.37 MP). An A4 page (21 × 29.7 cm) needs 2,480 × 3,508 pixels, about 8.7 MP.

DPI, PPI and why 300 is the usual target

Strictly, PPI (pixels per inch) describes how densely the image’s pixels are spread on paper, while DPI (dots per inch) describes the printer’s ink dots. In everyday use both mean the same thing here: how many image pixels go into each inch of the print.

At normal reading distance (about 30 cm), the human eye struggles to separate details finer than roughly 1/300 inch, which is why 300 PPI became the standard for photo labs and magazines. 240 PPI still looks sharp for most home prints, and 150 PPI is often enough for posters and banners viewed from a metre or more. The DPI value stored in a file’s metadata changes nothing in the pixels themselves; only the pixel count matters.

Common resolutions

Format Pixels Megapixels At 300 DPI
Full HD 1920 × 1080 2.07 16.26 × 9.14 cm
4K UHD 3840 × 2160 8.29 32.51 × 18.29 cm
12 MP phone (4:3) 4032 × 3024 12.19 34.14 × 25.6 cm
24 MP camera (3:2) 6000 × 4000 24 50.8 × 33.87 cm

A screen does not use DPI to display an image: a 1920-pixel-wide picture fills a Full HD screen whatever its metadata says.

Frequently asked questions

How many megapixels do I need for a 10 × 15 cm print?

At 300 DPI a 10 × 15 cm (4 × 6 in) print needs about 1181 × 1772 pixels, roughly 2.1 megapixels. Any modern phone exceeds that easily; resolution only becomes a constraint for large prints or heavy cropping.

How do I convert pixels to centimetres?

Divide the number of pixels by the resolution in DPI to get inches, then multiply by 2.54. For example, 3000 pixels at 300 DPI is 10 inches, or 25.4 cm. Without a resolution there is no fixed conversion.

Does changing the DPI in an editor improve quality?

No. Changing only the DPI value, without resampling, keeps exactly the same pixels and simply changes the intended print size. Enlarging the pixel dimensions (upscaling) invents pixels by interpolation and cannot add real detail.

Why is my JPEG much smaller than the size shown?

The calculator gives the uncompressed size. JPEG and HEIC compression typically shrink a photo 5 to 20 times, and PNG compresses losslessly by a smaller factor. Uncompressed size still tells you how much memory the image takes once opened.

What is the difference between MB and MiB?

A megabyte (MB) is 1,000,000 bytes; a mebibyte (MiB) is 1,048,576 bytes. Storage makers use MB, while some operating systems show MiB but label it MB, which is why the same file can appear about 5 % smaller.

Sources

Last updated:

More Other calculators

People also use