Skip to content
Menu

EM to Pixels

Em (em) to pixels (px) at any parent font size.

Result24px

Parent font size (px, for em)

Precision (significant figures)

Formula

px = em × parent size

1 em = 16 px with a 16 px parent font size

px = em × parent font size. With the default 16 px parent, 1 em is 16 px and 1.5 em is 24 px. Inside a 20 px heading the same 1.5 em becomes 30 px, so set the parent size to match your CSS.

Formula

px = em × parent size

Worked example

  1. Start with 1.5 em.
  2. Multiply by the parent font size (16 px): 1.5 × 16 = 24 px.

Em to px chart

Values in pixels for common parent font sizes. em compounds when nested.

Em (em)14 px16 px18 px20 px
0.1251.7522.252.5
0.253.544.55
0.578910
0.7510.51213.515
0.87512.251415.7517.5
114161820
1.12515.751820.2522.5
1.2517.52022.525
1.521242730
1.7524.52831.535
228323640
2.535404550
342485460
456647280
5708090100
68496108120

When you need this conversion

Reading someone else’s CSS, checking a component library, or matching a design in Figma: em values only make sense once you know the pixel size they resolve to. Multiply by the font size they’re measured against.

Where em comes from

For font-size, em uses the parent element’s font size. For padding, margins, borders and widths, em uses the element’s own font size. Both are resolved to pixels before the browser draws anything.

Useful values with a 16 px base:

  • 0.5 em = 8 px
  • 0.75 em = 12 px
  • 1.25 em = 20 px
  • 2 em = 32 px

Compounding

If a 1.25em element sits inside another 1.25em element, the inner one is 1.25 × 1.25 = 1.5625 times the outer base. With a 16 px start that’s 25 px, not 20 px. When a design looks bigger than expected, nested em values are the usual cause.

Common mistakes

Using the root size instead of the parent. rem uses the root; em uses the parent. If the parent has its own font size, use that.

Forgetting padding uses the element’s own size. A button with font-size: 14px; padding: 1em has 14 px padding, not 16.

To go the other way, use pixels to em.

Questions

How many pixels is 1 em?

It equals the parent's font size: 16 px by default, 20 px inside a 20 px heading.

How many pixels is 0.875 em?

14 px with a 16 px parent.

How do I find the parent font size?

Open developer tools, select the parent element and read its computed font-size.

Is em the same in print?

Yes. In print style sheets em works the same way; it's always relative to a font size, not to paper.

Sources

Last reviewed 2026-09-24. How we check values · Report a problem with this page

Further reading

  • px, rem and em in CSS: when to use each

    Three length units, three different reference points. What each one is measured against, how they behave when a reader changes their font size, and a simple rule for choosing.