PX to REM Converter


An easy to use rem to px converter tool for web designers.



px
rem


px

Live Preview

Font Size = 0.625rem & Base Font Size = 16px

Sample



SHARE NOW


px


rem
1px to rem

px


rem
5px to rem

px


rem
10px to rem

px


rem
16px to rem

px


rem
20px to rem

px


rem
24px to rem

px


rem
28px to rem

px


rem
32px to rem

How to Use the converter?

1

Select the input field labeled "REM"

2

Change the number in an input field

3

Converter will automatically convert

What is REM?

In CSS, rem stands for "root em." It is a unit of measurement equal to the font size of the document's root element. The root element is usually the <html> element, and the font size is usually set on the <body> element.

Using rem units allows you to specify sizes in a way that is responsive to changes in the font size. For example, if you set the font size of the root element to be 16px, then 1rem would be equal to 16px. If you later change the font size of the root element to be 20px, then 1rem would automatically be updated to be equal to 20px.

The (REM) root element's font size can be set in pixels or relative to the user's default font size. If a pixel value is not specified, it will inherit from its parent elements, usually 16px by default.

What is px unit?

A pixel is the smallest unit of an image that can be displayed on a screen. In web development, pixels are used to define the size of an element on a web page.

One pixel is equal to one dot on a computer screen. The size of a pixel is not fixed, and it can vary depending on the device’s screen resolution.

Pixels are commonly used to define the size of images, fonts, and other elements on a web page. When you set the font size of an element to 16px, it means that the text will be displayed in 16 pixels on the screen.

Difference Between PX and REM

Pixels (px)

Pixels (px) are a fixed unit of measurement used in web design. They are based on the resolution of the display, meaning their size remains consistent across different devices and screen sizes. For example, an element set to 100px wide will always be 100 pixels wide, whether it’s viewed on a mobile phone or a large monitor. This makes px a great choice for elements that require precise dimensions, such as images, icons, or fixed layouts. However, since it doesn’t adapt to changes in the user’s browser settings or screen resolution, using pixels can lead to a lack of responsiveness and accessibility in some designs.

Root em (rem)

Root em (rem) is a relative unit of measurement that scales based on the font size of the root HTML element (). By default, most browsers set this root size to 16px, so 1rem typically equals 16px. What makes rem powerful is its ability to create scalable and responsive layouts. When a user changes their browser’s default font size or zoom level, elements using rem automatically adjust, ensuring better accessibility and a more flexible design. This makes rem ideal for font sizes, padding, margins, and other components that need to respond to various screen sizes and user preferences.

PX to REM Conversion Table (Base: 16px)

PX REM
1px 0.06rem
2px 0.13rem
3px 0.19rem
4px 0.3rem
5px 0.31rem
6px 0.38rem
8px 0.5rem
10px 0.625rem
12px 0.75rem
14px 0.875rem
15px 0.94rem
16px 1rem
18px 1.13rem
20px 1.25rem
24px 1.5rem
25px 1.56rem
28px 1.75rem
32px 2rem
36px 2.25rem
40px 2.5rem
44px 2.75rem
48px 3rem
50px 3.13rem
56px 3.5rem
64px 4rem
72px 4.5rem
75px 4.69rem
80px 5rem
90px 5.63rem
100px 6.25rem