What this tool does
A design handed over in pixels still has to become rems, ems and points. This converter applies one base font size to convert all common CSS length units at once. For em and %, the base is the parent font size, assumed equal to the root size here.
How to use it
- Enter a value and choose its unit.
- Set the base font size if it is not 16px.
- Copy the unit you need.
Questions
What is the difference between em and rem?
rem is relative to the root font size. em is relative to the parent element's font size, which this tool approximates with the same base.
How is percentage calculated?
For font sizes, 100% equals the base font size; the converter uses that assumption.
How many points are in a pixel?
1pt = 4/3px, so 12pt = 16px.