Skip to content

颜色和设计

CSS 单位转换器

免费的 CSS 单位转换器。基于根字体大小,在 px、rem、em、pt、pc 和物理单位之间进行转换。适用于响应式设计和 CSS 工作流程。

Runs in your browser

CSS units converter

rem
1rem
em
1em
pt
12pt
pc
1pc
in
0.1667in
cm
0.4233cm

编辑注

Understanding · px, rem, em, and the rest of the family.

本深度章节目前仅有英文版本。上方的转换工具支持您的语言;长篇说明文章尚未翻译。

常见问题

Quick answers.

Is 1rem always 16px?

By default, yes — but if you change the root font-size, all rem values scale. We let you set the root for accurate conversion.

rem vs em?

rem is relative to root font-size; em is relative to the parent's font-size. rem is more predictable for layout.

Why use rem over px?

rem respects user font-size preferences (for accessibility) and scales the whole layout consistently.

Is the converter free?

Yes — fully free, no signup.

大家也在搜索

相关工具

More in this room.

查看所有 颜色和设计