base value:
Value(Pixels):
Value(rem):
To convert PX (pixels) to REM (root em), you need to know the base font size (usually defined in the CSS). REM is a relative unit, based on the root element's font size, typically set in the HTML element.
The formula to convert from Pixels to REM is:
For example, if your base font size is 16 pixels (which is common), and you want to convert 24 pixels to REM:
24px ÷ 16px = 1.5rem
So, 24 pixels equals 1.5 REM if the base font size is 16 pixels. Make sure to adjust the base font size in the calculation according to your specific CSS settings.
Pixels | rem |
1 | 0.0625 |
2 | 0.125 |
3 | 0.1875 |
4 | 0.25 |
5 | 0.3125 |
6 | 0.375 |
7 | 0.4375 |
8 | 0.5 |
9 | 0.5625 |
10 | 0.625 |
11 | 0.6875 |
12 | 0.75 |
13 | 0.8125 |
14 | 0.875 |
15 | 0.9375 |
16 | 1 |
17 | 1.0625 |
18 | 1.125 |
19 | 1.1875 |
20 | 1.25 |
21 | 1.3125 |
22 | 1.375 |
23 | 1.4375 |
24 | 1.5 |
25 | 1.5625 |
26 | 1.625 |
27 | 1.6875 |
28 | 1.75 |
29 | 1.8125 |
30 | 1.875 |
31 | 1.9375 |
32 | 2 |
33 | 2.0625 |
34 | 2.125 |
35 | 2.1875 |
36 | 2.25 |
37 | 2.3125 |
38 | 2.375 |
39 | 2.4375 |
40 | 2.5 |
41 | 2.5625 |
42 | 2.625 |
43 | 2.6875 |
44 | 2.75 |
45 | 2.8125 |
46 | 2.875 |
47 | 2.9375 |
48 | 3 |
49 | 3.0625 |
50 | 3.125 |