# PX / PT / DP converter

### PT (Point)

pt
Logical dpipxmm
Mac (Non-Retina)72dpi--
Windows (scale 100%)96dpi--
Windows (scale 125%)120dpi--
Windows (scale 150%)
Mac (Retina)
iPhone (4/5/SE/6/XR)
144dpi--
iPhone（X/XS/11）216dpi--
dpi00

### DP (Density-independent pixel)

dp
Logical dpipxmm
ldpi120dpi--
mdpi160dpi--
tvdpi213dpi--
hdpi240dpi--
xhdpi320dpi--
xxhdpi480dpi--
xxxhdpi640dpi--
dpi00

This is a tool to convert px, pt, dp / dip, mm for each dpi. There is also a calculation formula for the conversion.

• Round to the third decimal place.
• "mm" is the print size, not the size on the display.

## How to conversion

### pt (Point)

$px={\dfrac {pt \times dpi}{72}}$ $pt={\dfrac {px \times 72}{dpi}}$

pt (point) is a unit of size mainly used in publications and is defined as “1 pt = 1/72 inch”.

### dp (Density-independent pixel)

$px={\dfrac {dp \times dpi}{160}}$ $dp={\dfrac {px \times 160}{dpi}}$

dp (density-independent pixel / dip) is a unit of size mainly used in android. 1 dp is defined as approximately equal to 1px at mdpi (160 dpi). So 1dp = 1px at mdpi and 1 dp = 2 px at xhdpi (320 dpi).

### mm (Millimetre)

$px={\dfrac {mm \times dpi}{25.4}}$ $mm={\dfrac {px \times 25.4}{dpi}}$

It is defined as 1 inch = 25.4 mm.

In the display, the physical size changes depending on the resolution, so it cannot be expressed in mm.