ratio.

Find a tool

Browse all tools and categories ↗
WEB DESIGN

CSS Font Size Converter

Convert px, rem, em, percent and CSS point sizes using separate entered root and parent font sizes.

Enter your values

01 / INPUT
Calculated on your device

YOUR CALCULATION

Result

—

Calculation steps

Work through one step at a time or reveal the complete calculation. The steps use your current inputs.

    How to calculate

    Use CSS pixels as a reference while applying the correct font-size context to em, rem and percent.

    px=rem×root; px=em×parent; px=percent×parent/100; 1pt=96/72 CSS px

    Worked example

    24 CSS px is 1.5 rem with a 16 px root, but 1.2 em with a 20 px parent. It is 18 CSS pt.

    Assumptions and input details

    This specifically converts values for the font-size property of a non-root child. em in other properties may refer to the element’s own font size instead. Root and parent values are entered computed sizes, with no assumption that 16 px is universal. CSS absolute ratios do not measure physical screen pixels or font glyph dimensions.

    References: W3C CSS Values and Units: font-relative and absolute lengths

    Using this calculator

    Can I enter my own problem?

    Yes. Replace the example values with your own inputs. The result, calculation steps, tables and applicable diagrams update from those inputs. Blank or invalid values clear the result; example values are never silently substituted for missing inputs.

    Are the results exact?

    Results use floating-point arithmetic and displayed rounding. Read the formula, assumptions and any stated data precision before interpreting the result.

    Is my input uploaded?

    The calculation runs in your browser. No account, file upload or external AI service is required. Inputs are not saved between page reloads.

    RELATED TOOL · DESIGNPrint Size and Image Resolution Calculator

    Convert pixel dimensions, print dimensions and pixels per inch. Find physical print size, required whole pixels or effective image resolution.

    RELATED TOOL · DESIGNPrint Sheet Imposition Calculator

    Compare two uniform rectangle orientations and estimate sheets with margins, bleed and cutting gaps.

    RELATED TOOL · GEOMETRYRectangle Overlap and IoU Calculator

    Calculate intersection area, union area and coverage fractions for two axis-aligned rectangles.

    ADVERTISEMENT

    Reserved advertising space.