Px: pixel, pixel, the smallest unit displayed on the screen, used for Webpage Design, intuitive and convenient;
PT: point, a standard unit of length, 1pt = 1/72 inch, used in the printing industry, very easy to use;
EM: %. In CSS, 1em = 100% is a ratio, which is used in combination with CSS inheritance relationships and is flexible.
PPI (DPI): pixel (DOT) per inch, number of pixels (points) per inch, which is a rate, indicating "resolution" and "accuracy"
Formula for Px AND Pt conversion:
PT = px multiplied by 3/4.
Formula for PX and EM conversion:
Em = 16 multiplied by PX, that is, 1.5em = 1.5 × 16 = 24px.
Commonly used Px/EM/Pt/percentage conversion tables in Design
Pixels |
6px |
7px |
8px |
9px |
10px |
11px |
12px |
13px |
14px |
15px |
16px |
17px |
18px |
19px |
20px |
21px |
22px |
23px |
24px |
EMS |
0.375em |
0.438em |
0.5em |
0.563em |
0.625em |
0.688em |
0.75em |
0.813em |
0.875em |
0.938em |
1em |
1.063em |
1.125em |
1.188em |
1.25em |
1.313em |
1.375em |
1.438em |
1.5em |
Percent |
37.5% |
43.8% |
50% |
56.3% |
62.5% |
68.8% |
75% |
81.3% |
87.5% |
93.8% |
100% |
106.3% |
112.5% |
118.8% |
125% |
131.3% |
137.5% |
143.8% |
150% |
Points |
5pt |
5.5pt |
6pt |
7pt |
8pt |
8pt |
9pt |
10pt |
11pt |
11pt |
12pt |
13pt |
14pt |
14pt |
15pt |
16pt |
17pt |
17pt |
18pt |