Conversion Table
Centimeters | Root Em |
---|---|
0.1cm | 0.236rem |
0.5cm | 1.181rem |
1cm | 2.362rem |
2cm | 4.724rem |
3cm | 7.086rem |
4cm | 9.448rem |
5cm | 11.811rem |
6cm | 14.173rem |
7cm | 16.535rem |
8cm | 18.897rem |
9cm | 21.259rem |
10cm | 23.622rem |
15cm | 35.433rem |
20cm | 47.244rem |
25cm | 59.055rem |
30cm | 70.866rem |
35cm | 82.677rem |
40cm | 94.488rem |
Differences Between cm and rem
Centimeters (cm) are a metric unit of length commonly used in physical measurements. Root Em (rem) is a relative unit based on the root element's font size in digital displays.
Advantages of Using cm
Using centimeters provides a physical measurement that can be easily converted to digital units like rem for web design and other digital applications.
How to Convert cm to rem
To convert centimeters to rem, use the following formula:
rem = cm * (96 / 2.54 / root font-size)
For example, to convert 2cm to rem with a root font-size of 16px:
2cm * (96 / 2.54 / 16) = 4.724rem
Frequently Asked Questions
Why should I use cm instead of rem?
Centimeters provide a physical measurement that is easy to understand and use in real-world applications. Rem units are more suitable for digital displays and web design.
How do I set sizes using cm in CSS?
In CSS, you can set sizes using the cm unit, for example:
width: 10cm;
Can I mix cm and rem units?
It's possible but not recommended. Stick to one unit for consistency in your designs.