How it works
rem = pixels / root font size; pixels = rem × root font size.
Input definitions
- Size to convert
- Enter the value in the labeled unit.
- Root font size (px)
- Enter the value in the labeled unit.
- Direction
- Choose Pixels to rem / Rem to pixels.
A worked example
- Size to convert
- 24
- Root font size (px)
- 16
- Direction
- Pixels to rem
Assumptions & limits
Root size is manually entered and is not assumed to match every visitor’s browser. Signed CSS lengths are supported.
Sources & review
Maintained by AnsRio. Methods and examples use automated checks; this does not imply independent professional certification.
Method updated 2026-10-17. Content checked against the stated method and examples. Our verification approach.
Common questions
Is 1 rem always 16 pixels?
No. A rem is relative to the root element’s computed font size. Sixteen pixels is a common default, but browser preferences and site CSS can change it. Enter the root size you intend to use.
Does generated CSS or a color result guarantee an accessible design?
No. Test the result in its real layout, including text contrast, browser zoom, focus and responsive behavior. A code generator only covers its documented property or color operation.
How does the Pixels and rem converter tool work?
rem = pixels / root font size; pixels = rem × root font size.
What are the assumptions and limits of Pixels and rem converter?
Root size is manually entered and is not assumed to match every visitor’s browser. Signed CSS lengths are supported.