⚡
usefultools.dev
px ↓ rem

CSS Units Converter

Convert between px, rem, vw, vh, vmin and vmax in your browser, using your own root font size and window size.

Funciona 100% no seu navegador — o que você insere nunca é enviado nem armazenado nos nossos servidores.

Esta ferramenta ainda não está totalmente traduzida, por isso parte do texto continua em inglês. A ferramenta funciona da mesma forma em todos os idiomas.

Converts between px, rem, vw, vh, vmin, and vmax.
(Viewport: 1920px × 1080px, Root font size: 16px)

to

Please enter a valid number.

⚡

Exemplos rápidos

Entradas típicas e os resultados que esta ferramenta gera.

To rem
16px
1 rem
To rem
24px
1.5 rem
To rem
10px
0.625 rem
To px
2.5rem
40 px
To px
50vw (1920px wide)
960 px
📖

Visão geral

CSS Units Converter turns a value in px, rem, vw, vh, vmin or vmax into any other unit from that list, so you can move a design from fixed pixel measurements to scalable rem sizes or viewport-relative sizing.

Front-end developers use it when translating a design file into CSS, or to check how many pixels 5vw actually is. Rem results use the root font size of the page (normally 16px), and vw, vh, vmin and vmax use the current size of your browser window. Both numbers are shown above the form, and the window size updates when you resize it.

The result is rounded to four decimals and calculated in your browser, so nothing is sent anywhere. The em unit is not offered, because it depends on the font size of a parent element that a standalone converter cannot know.

Por que usar esta ferramenta?

  • Improve responsive design and scalability
  • Better accessibility for users with custom font settings
  • Save time and avoid manual calculations
  • Perfect for developers and designers
  • Free to use, no sign-up required
⭐

Recursos

⚡

Instant result

The result is calculated as you type — no button click needed.

🔄

Six CSS units

Converts between px, rem, vw, vh, vmin and vmax in any direction.

📐

Root font size read

Rem conversions use the root font size of the page, shown above the form.

🖥️

Live viewport size

vw, vh, vmin and vmax use your current window size and follow window resizing.

🔢

Clean rounding

Results are rounded to four decimals with trailing zeros removed.

⚠️

Input check

An empty or invalid number shows a clear message instead of a wrong result.

🔒

Runs in your browser

Calculations happen locally, with no account and no data sent to a server.

🛠️

Como usar

1

Enter the value

Type the number you want to convert into the value field (16 is filled in by default).

2

Select units

Pick the unit to convert from in the first dropdown and the target unit in the second, after "to".

3

Read the result

The converted value appears below the form as you type or change a unit.

4

Use it in your CSS

Select the result text, copy it and paste it into your stylesheet.

🤔

Perguntas frequentes