Toolman

12px to em

12px = 0.75em

At the browser default font size of 16 px. Change it and this number changes — see below.

How it is calculated

One px is 0.0625em, so:

12px × 0.0625 = 0.75em

Reversing it, 0.75em × 16 returns 12px.

12px at other font sizes

em is measured against the element's own font size, inherited from its parent unless it sets one, so the answer above holds only while that is 16 px. Nested elements each compound on their parent, so this is the value for one level, not for the whole tree.

Font size12px equals
14 px0.857143em
16 px (default)0.75em
18 px0.666667em
20 px0.6em
24 px0.5em

Nearby values

pxem
8px0.5em
10px0.625em
12px0.75em
14px0.875em
16px1em
18px1.125em
20px1.25em

Frequently asked questions

What is 12px in em?

0.75em at the default 16 px font size.

How is 12px converted to em?

Multiply by 0.0625: 12 × 0.0625 = 0.75. To go back, multiply 0.75 by 16.

Is 0.75em always the answer?

No. em is relative to the element's own font size, inherited from its parent unless it sets one, so 12px is 0.75em only while that is 16 px. The table above gives the value at the sizes you are most likely to meet.

The full PX to EM converter → · All CSS unit converters