PPI Calculator

Calculate screen pixels per inch (PPI) and dot pitch from resolution and diagonal size.

Back to all tools on ToolForge

More in Calculators







Result

PPI: pixels per inch

Dot pitch: mm

About PPI Calculator

PPI (pixels per inch) measures screen pixel density, indicating how many pixels fit in one inch of display space. Higher PPI values produce sharper, more detailed images with less visible pixelation. This calculator computes PPI and dot pitch from screen resolution and diagonal size.

PPI Calculation Formula

PPI is calculated using the Pythagorean theorem to find the diagonal resolution in pixels:

PPI Calculation:

Step 1: Calculate diagonal resolution (pixels)
  diagonal_pixels = √(width² + height²)

Step 2: Divide by screen diagonal (inches)
  PPI = diagonal_pixels / screen_diagonal

Step 3: Calculate dot pitch (mm)
  dot_pitch = 25.4 / PPI

Example: 1920×1080 at 24 inches
  diagonal_pixels = √(1920² + 1080²)
                  = √(3,686,400 + 1,166,400)
                  = √4,852,800
                  = 2,202.9 pixels

  PPI = 2,202.9 / 24
      = 91.79 pixels per inch

  dot_pitch = 25.4 / 91.79
            = 0.277 mm

JavaScript Implementation

function calculatePPI(width, height, diagonal) {
  // Validate inputs
  if (!width || !height || !diagonal || diagonal <= 0) {
    throw new Error("Invalid input values");
  }

  // Calculate diagonal resolution using Pythagorean theorem
  const diagonalPixels = Math.sqrt(width * width + height * height);

  // Calculate PPI
  const ppi = diagonalPixels / diagonal;

  // Calculate dot pitch in millimeters
  // 1 inch = 25.4 mm
  const dotPitch = 25.4 / ppi;

  return {
    ppi: ppi.toFixed(2),
    dotPitch: dotPitch.toFixed(3),
    diagonalPixels: diagonalPixels.toFixed(1)
  };
}

// Usage examples:
calculatePPI(1920, 1080, 24);   // 91.79 PPI, 0.277mm
calculatePPI(3840, 2160, 27);   // 163.18 PPI, 0.156mm
calculatePPI(2560, 1440, 27);   // 108.79 PPI, 0.233mm

Common Resolution PPI Reference

Resolution Name 24" 27" 32"
1920×1080 Full HD (1080p) 91.8 PPI 81.6 PPI 68.8 PPI
2560×1440 QHD (1440p) 122.4 PPI 108.8 PPI 91.8 PPI
3840×2160 4K UHD (2160p) 183.5 PPI 163.2 PPI 137.6 PPI
5120×2880 5K 244.7 PPI 217.5 PPI 183.5 PPI
7680×4320 8K UHD 367.0 PPI 326.2 PPI 275.2 PPI

Device PPI Comparison

Device Type Typical PPI Range Example Viewing Distance
Smartphones 300-500+ PPI iPhone 15 Pro: 460 PPI 10-12 inches
Tablets 264-400 PPI iPad Pro: 264 PPI 15-18 inches
Laptops 100-220 PPI MacBook Pro 14": 254 PPI 18-24 inches
Desktop Monitors 80-200 PPI 27" 4K: 163 PPI 24-36 inches
Televisions 40-80 PPI 55" 4K: 80 PPI 6-10 feet

Retina / HiDPI Thresholds

"Retina" (Apple) and "HiDPI" refer to displays where pixels are indistinguishable at normal viewing distance for 20/20 vision:

Viewing Distance Required PPI Device Category
10-12 inches 287-344 PPI Smartphones
15-18 inches 191-229 PPI Tablets
18-24 inches 143-191 PPI Laptops/Monitors
36 inches 96 PPI Large monitors
6 feet (72 inches) 48 PPI Televisions
10 feet (120 inches) 29 PPI Large TVs/Projectors

PPI and Dot Pitch Relationship

Dot pitch is the physical distance between adjacent pixel centers, measured in millimeters:

PPI to Dot Pitch Conversion:
  dot_pitch_mm = 25.4 / PPI

Dot Pitch to PPI Conversion:
  PPI = 25.4 / dot_pitch_mm

Reference Table:
  PPI     | Dot Pitch (mm) | Quality
  --------|----------------|------------------
  72      | 0.353          | Standard (old CRT)
  96      | 0.265          | Standard LCD
  110     | 0.231          | Entry laptop
  144     | 0.176          | Good quality
  200     | 0.127          | High density
  300     | 0.085          | Retina class
  400     | 0.064          | Premium smartphone
  500     | 0.051          | Cutting edge phone

Design Considerations for HiDPI

When designing for HiDPI/Retina displays:

Common Use Cases

PPI vs DPI

Aspect PPI (Pixels Per Inch) DPI (Dots Per Inch)
Definition Screen pixel density Print dot density
Used For Digital displays Printing, scanning
Standard Values 72-500+ PPI 150-600+ DPI
CSS Reference 96 PPI (web standard) N/A
Print Quality N/A 300 DPI standard

Limitations

How to Use PPI Calculator

  1. Enter width: Input the horizontal resolution in pixels (e.g., 1920).
  2. Enter height: Input the vertical resolution in pixels (e.g., 1080).
  3. Enter diagonal: Input the screen diagonal size in inches (e.g., 24).
  4. Calculate: PPI and dot pitch are automatically calculated.
  5. Compare: Use results to compare display sharpness across devices.

Tips

Frequently Asked Questions

How is PPI calculated?
PPI is calculated using the Pythagorean theorem: PPI = √(width² + height²) / diagonal. First, calculate the diagonal resolution in pixels using √(width² + height²), then divide by the screen diagonal in inches. For example, a 1920×1080 display at 24 inches: √(1920² + 1080²) = 2202.9 pixels, divided by 24 = 91.8 PPI.
What is dot pitch and how does it relate to PPI?
Dot pitch is the distance between adjacent pixels, measured in millimeters. It's the inverse of PPI: Dot Pitch (mm) = 25.4 / PPI. Higher PPI means smaller dot pitch and sharper images. For example, 96 PPI = 0.265mm dot pitch, while 300 PPI = 0.085mm dot pitch.
What is considered Retina or HiDPI display?
Retina (Apple) and HiDPI (general) refer to displays where individual pixels are indistinguishable at normal viewing distance. Thresholds vary: smartphones need ~300+ PPI (viewed at 10-12 inches), tablets need ~264 PPI (15-18 inches), monitors need ~200+ PPI (24-36 inches). The required PPI decreases as viewing distance increases.
Why does PPI matter for design work?
PPI affects pixel density and sharpness. High PPI displays (HiDPI/Retina) require 2x or 3x resolution assets for crisp rendering. Design tools use PPI to scale UI elements correctly. Web design assumes 96 PPI (CSS pixel), but actual device PPI varies widely. Understanding PPI ensures designs look sharp across devices.
What are common PPI values for different devices?
Smartphones: 300-500+ PPI (iPhone 15: 460 PPI, Galaxy S24: 390-500 PPI). Tablets: 264-400 PPI (iPad: 264 PPI). Laptops: 100-220 PPI (MacBook Pro: 220-254 PPI). Monitors: 80-200 PPI (27" 4K: 163 PPI). TVs: 40-80 PPI (55" 4K: 80 PPI, viewed from 6+ feet).
How does viewing distance affect perceived sharpness?
Perceived sharpness depends on angular pixel density. At 20/20 vision, the human eye resolves ~1 arcminute (1/60 degree). Required PPI = 3438 / viewing distance (inches). At 12 inches: 287 PPI needed. At 24 inches: 143 PPI. At 10 feet (TV): 29 PPI. This is why TVs can have lower PPI than phones.