Pixels to DPI Converter

Use this CSS unit converter tool to easily convert Pixel into DPI.

On this page, you’ll learn:

  • What is Pixels in CSS?
  • What is DPI?
  • Pixels to DPI Conversion Formula
  • How to Convert Pixels into DPI?
  • Pixels to DPI Conversion Table

What is a Pixel to DPI Converter?

Pixel to DPI Converter is an online CSS unit converter tool through which you can convert Pixels into its equivalent value in DPI.

Pixels to DPI Converter

What is a Pixel?

A pixel is the smallest area on a computer screen which together forms the whole image. A pixel is represented using the symbol px.

What is a DPI?

DPI stands for Dots Per Inch and refers to the number of ink droplets a printer will produce per inch while printing an image. The higher the amount of DPI will be, the more detailed picture will be printed.

DPI is used to define the resolution of a printer, scanner or mouse.

Pixels to DPI Conversion Formula

The formula used to convert Pixels to DPI is:

DPI = Diagonal (in Pixels) / Diagonal (in Inches)

The diagonal in Pixel is calculated using the following formula:

Diagonal (in Pixels) = √(Height2 + Width2)

How to Convert Pixels into DPI?

Pixel can be calculated into DPI, if we know the measure of the diagonal in pixels and diagonal in inches. First, we have to calculate the diagonal in Pixels. This can be easily calculated if we know the dimensions of the image. If the height and width are known, then we can use the Pythagorean theorem to find the diagonal in pixels.

Diagonal (in Pixels) = √(Height2 + Width2)

Once the diagonal in pixels is calculated, then we can use the Pixels to DPI Conversion formula to find out the DPI.

Pixel to DPI Conversion Table

Output SizePixelsDPI


Scroll to Top