Skip to content
MoneyDeck

Megapixel Calculator

Convert pixel dimensions to megapixels — and megapixels back to pixels

Updated · Free, no signup

px
px

Resolution

6,000 × 4,000 px (24 MP)

Megapixels

24 MP

Total pixels

24,000,000

Width

6,000 px

Height

4,000 px

Aspect ratio

3:2

Max print at 300 PPI

20 × 13.33 in

Uncompressed size (24-bit RGB)

72 MB

  • At 300 PPI this image prints at up to 20 × 13.3 inches (50.8 × 33.9 cm).
  • Cropping to half the width and height keeps only a quarter of the pixels: 6 MP.

The same pixel count at other aspect ratios

Aspect ratioPixels (W × H)Megapixels
3:26,000 × 4,00024
4:35,657 × 4,24324
16:96,532 × 3,67424
1:14,899 × 4,89924
5:45,477 × 4,38224
21:97,483 × 3,20724

About the Megapixel Calculator

This megapixel calculator converts between an image’s pixel dimensions and its megapixel count in both directions. Enter a width and height to see the total pixels, megapixels, aspect ratio and the largest photo-quality print it supports, or enter a megapixel figure and an aspect ratio to see the width and height in pixels that a camera of that resolution produces.

It helps when comparing camera or phone specifications, checking whether an image meets a stock-agency or print-shop minimum, estimating how much detail you keep after cropping, or working out what “a 12 MP photo” actually means in pixels. The table shows the same pixel count reshaped to the other common aspect ratios.

One megapixel is one million pixels (10⁶), the definition camera makers use. Real sensors often have slightly different dimensions from the idealised figures here, because manufacturers round marketing numbers and reserve some pixels at the edges.

How to use the megapixel calculator

  1. 1Choose whether you are starting from pixel dimensions or from a megapixel number.
  2. 2Enter the width and height in pixels, or the megapixels and aspect ratio.
  3. 3Read the megapixels or the pixel dimensions in the results.
  4. 4Check the 300 PPI print size to see how large you can print.
  5. 5Use the table to see the same resolution in other aspect ratios.

Formula and method

MP = (W × H) ÷ 1,000,000
W = √(MP × 10⁶ × a ÷ b), H = W × b ÷ a

Megapixels are simply the total pixel count divided by one million. Going the other way, a megapixel figure fixes the area but not the shape, so you also need the aspect ratio a:b. The width is the square root of the pixel count multiplied by a/b, and the height follows from the ratio; both are rounded to whole pixels, so the result can differ from the target by a tiny fraction of a megapixel.

The 300 PPI print size divides each dimension by 300, the usual standard for photo-quality prints viewed up close. The uncompressed size assumes 3 bytes per pixel (8 bits each for red, green and blue); JPEG files are typically 5–15 times smaller.

W, H
Width and height in pixels
MP
Megapixels (millions of pixels)
a:b
Aspect ratio (width : height)

Worked examples

6000 × 4000 px camera file

6000 × 4000 = 24,000,000 pixels, or 24 MP, in the 3:2 shape of most interchangeable-lens cameras. At 300 PPI it prints at 20 × 13.33 inches, and the raw RGB bitmap is 72 MB.

A 12 MP phone photo at 4:3

For 4:3, width = √(12,000,000 × 4 ÷ 3) = 4000 px and height = 4000 × 3 ÷ 4 = 3000 px — the familiar 4000 × 3000 phone resolution.

4K UHD video frame

A 3840 × 2160 UHD frame holds 8,294,400 pixels — about 8.3 MP — in a 16:9 shape, so a 4K video still is roughly as detailed as an 8 MP photo.

45 MP at 3:2

Width = √(45,000,000 × 1.5) ≈ 8216 px and height = 8216 × 2 ÷ 3 ≈ 5477 px, close to the 8256 × 5504 sensors of 45 MP full-frame cameras.

Frequently asked questions

How many pixels is 1 megapixel?+

One megapixel is exactly 1,000,000 pixels. A 1000 × 1000 image is 1 MP, and a 4000 × 3000 image is 12 MP.

How many megapixels is 4K?+

A 4K UHD frame is 3840 × 2160 pixels, which is about 8.3 megapixels. DCI 4K used in cinema is 4096 × 2160, about 8.8 megapixels.

Do more megapixels mean better photos?+

More megapixels allow larger prints and more cropping, but image quality also depends on sensor size, lens sharpness and light. Doubling megapixels only increases linear resolution by about 41%.

How many megapixels do I need to print?+

For a photo-quality 300 PPI print, an 8 × 10 inch print needs 2400 × 3000 pixels (7.2 MP) and a 4 × 6 needs 1200 × 1800 (2.2 MP). Large prints viewed from farther away can use 150–200 PPI.

Why does my camera’s pixel count differ from the advertised megapixels?+

Manufacturers often quote “effective” megapixels rounded to a convenient number, and sensors include masked border pixels used for calibration, so the image file dimensions rarely match the headline exactly.

Related tools