Pixel, DPI & Print Size Calculator
Free pixel calculator: screen PPI, megapixels, print size at any DPI, aspect-ratio detection and a live CSS-vs-device-pixel readout — all in your browser.
—
Exact math: ppi = √(width² + height²) ÷ diagonal. Vendor claims are usually rounded — an advertised "460 ppi" phone often computes to 461-ish.
—
| printed at | size (inches) | size (cm) |
|---|
240–300 ppi is photo quality at reading distance; 150 ppi is plenty for a poster seen across a room. The reasoning is in the print-resolution guide.
Pixels → print size
—
Print size → pixels needed
—
Same dpi as the left side — pixels = inches × dpi.
—
Reduced by the greatest common divisor, then compared with broadcast, photo and cinema standards — including near-misses (1366×768 is not exactly 16:9, and most "21:9" monitors aren't either).
Live values from this device — zoom the page or move the window to another display and they change. Why they differ: CSS pixels vs device pixels.
The five modes, one line each
Screen PPI takes a resolution and a diagonal and returns the display’s pixel density — exact, not the rounded number on the box. Megapixels turns width × height into the camera-industry unit and a print-size table at five standard densities. Print size runs the other direction too: pixels ÷ dpi gives inches; a target sheet size × dpi gives the pixels you need. Aspect ratio reduces a resolution by its greatest common divisor and names the nearest real standard. CSS pixels reads this device’s devicePixelRatio, screen and viewport as the browser reports them — the numbers web developers actually get.
The math behind it
Everything on this page is closed-form arithmetic you can check with a pocket calculator:
- Pixel density:
ppi = √(w² + h²) ÷ diagonal— the diagonal in pixels divided by the diagonal in inches. Also reported as pixels-per-millimeter and dot pitch (the physical size of one pixel). - Megapixels:
MP = w × h ÷ 1,000,000. A “24 MP” camera is really ≈24.0 MP because 6000×4000 is exactly 24,000,000 — while a “12 MP” phone at 4032×3024 is actually 12.19 MP. - Print size:
inches = pixels ÷ dpi,cm = inches × 2.54. Reversed:pixels = inches × dpi— how big a file a 8×10 at 300 dpi demands (2,400 × 3,000). - Aspect ratio: divide both sides by
gcd(w, h)— 1920×1080 → 16:9, 1366×768 → 683:384, which is why the nearest-standard check exists. - Device pixels:
device px = css px × devicePixelRatio— the abstraction that keeps 1-pixel borders visible on 3× phones.
Presets, and a note on honesty
The device presets use manufacturers’ published panel resolutions and diagonals — and where the advertised PPI disagrees with the arithmetic (it often does, always downward-rounded), this page shows the computed figure. For print sizes, A-series papers are exact millimeter definitions converted at 1 in = 25.4 mm, so “A4 at 300 dpi” comes out 2,480 × 3,508 px like every professional prepress table.
Deeper reading: PPI vs DPI · how much resolution print really needs · why 4K isn’t 4000 pixels · CSS pixels vs device pixels.
Everything runs in your browser — nothing you measure is transmitted, logged or stored.
Frequently asked questions
Is PPI the same thing as DPI?
Not quite. PPI (pixels per inch) measures a digital image or display's sampling density; DPI (dots per inch) measures the ink dots a printer physically places. One image pixel is typically rendered by many ink dots, which is why a 1440-dpi printer happily prints a 300-ppi file. The full distinction — and when each term is the honest one — is in PPI vs DPI.
Why does the calculator say my iPhone is 461 ppi when Apple says 460?
Because the marketing number is rounded. PPI here is computed exactly — √(width² + height²) ÷ diagonal — so an iPhone 15's 1179×2556 on a 6.1-inch diagonal gives ≈461.4 ppi, which Apple advertises as 460. Small differences also come from the advertised diagonal being nominal: the actual panel may measure 6.06 or 6.12 inches. The math is exact; the spec sheet is rounded.
Do I always need 300 DPI for printing?
Only when the print will be examined at reading distance — books, magazines, photo prints. A poster viewed from two meters away looks identical at 100–150 dpi, and a billboard can be 15 dpi. The real rule is angular resolution, not a fixed number; how much resolution you actually need works through the viewing-distance math.
Why is "4K" 3840 pixels and not 4000?
Because consumer 4K is UHD — exactly twice 1920×1080 — while true DCI 4K cinema is 4096×2160. Marketing borrowed the rounder cinema name for the TV standard. The whole story, including where 8K and QHD fit, is in why 4K isn't 4000 pixels.
Why does my laptop report 1440×900 when the spec says 2560×1600?
Because the browser reports CSS pixels, not device pixels. On a 2× display, devicePixelRatio is 2 and each CSS pixel maps to a 2×2 block of physical pixels — that's what makes text look crisp instead of tiny. The CSS-pixels tab above shows your live values; the explainer covers the mechanics.
Is a "21:9" ultrawide monitor really 21:9?
Usually not. A 3440×1440 ultrawide reduces to 43:18 (≈2.39:1 — cinema ratio, not 21:9's 2.33:1), and 2560×1080 is 64:27. The aspect-ratio tab shows the exact reduced ratio plus the closest standard, so the marketing label doesn't have to be taken on faith.
Do the numbers I enter get sent anywhere?
No. Every mode is plain JavaScript running in this tab — there is no server doing the math, nothing is logged, and the page keeps working if you go offline after it loads. The privacy policy has the whole picture.
Latest articles
Why '4K' Is 3840 Pixels, Not 4000
There are two different 4Ks. TVs got the smaller one, cinemas kept the real one, and the marketing name stuck to the wrong box.
CSS Pixels vs Device Pixels: Why Your Screen Lies About Its Resolution
devicePixelRatio is the translator between the web's abstract pixel and the panel's physical one — here's the whole mechanism.
PPI vs DPI: What the Two Units Actually Measure
One measures pixels, the other measures ink dots — and using them interchangeably is why so many print specs read like nonsense.
How Much Resolution Do You Need to Print? It's About Viewing Distance
300 dpi is a reading-distance convention. Posters, banners and billboards play by different math — here's the size-by-size breakdown.