Technology· Tools for builders
Convert between px, rem, em, pt, vw and vh for a given root font size and viewport.
Formula
rem = px ÷ root font size; pt = px × 0.75; vw = px ÷ viewport width × 100
Worked example
24 px with a 16 px root: 1.5 rem, 18 pt, 1.875 vw on a 1,280 px wide viewport.
Free to use with a link back. Nothing you type is shared.
Preparing citation…
Keep exploring
Generate a fluid CSS clamp() value that scales between two screen widths.
Open calculatorCalculate a display's pixel density (pixels per inch) and dot pitch from resolution and diagonal size.
Open calculatorReduce image or screen dimensions to their simplest whole-number ratio.
Open calculator