CSS Unit Converter
Comprehensive CSS unit converter with 20+ units, visual preview, responsive analysis, CSS generation, and device presets.
Convert CSS Units
absolute
px - PixelsConversion Results (26 units)
| Unit | Value | Type | Description | Copy |
|---|---|---|---|---|
| px | 16.0000px | absolute | Device pixels, most common unit | |
| pt | 12.0000pt | absolute | 1/72 of an inch, used in print | |
| pc | 1.000000pc | absolute | 12 points, typography unit | |
| in | 0.166667in | absolute | Physical inches | |
| cm | 0.423333cm | absolute | Physical centimeters | |
| mm | 4.233333mm | absolute | Physical millimeters | |
| Q | 16.9333Q | absolute | Quarter of a millimeter | |
| rem | 1.000000rem | relative | Relative to root element font size | |
| em | 1.000000em | relative | Relative to parent element font size | |
| ex | 2.000000ex | relative | Height of lowercase x | |
| ch | 1.666667ch | relative | Width of character "0" | |
| lh | 0.833333lh | relative | Line height of element | |
| rlh | 0.833333rlh | relative | Line height of root element | |
| % | 100.000% | relative | Relative to parent element | |
| vw | 0.833333vw | viewport | 1% of viewport width | |
| vh | 1.481481vh | viewport | 1% of viewport height | |
| vmin | 1.481481vmin | viewport | 1% of smaller viewport dimension | |
| vmax | 0.833333vmax | viewport | 1% of larger viewport dimension | |
| vi | 0.833333vi | viewport | 1% of viewport inline axis | |
| vb | 1.481481vb | viewport | 1% of viewport block axis | |
| cqw | 0.833333cqw | container | 1% of container width | |
| cqh | 1.481481cqh | container | 1% of container height | |
| cqi | 0.833333cqi | container | 1% of container inline size | |
| cqb | 1.481481cqb | container | 1% of container block size | |
| cqmin | 1.481481cqmin | container | 1% of smaller container dimension | |
| cqmax | 0.833333cqmax | container | 1% of larger container dimension |
Device Presets
Context Settings
Used for rem, em, and % calculations
Used for vw, vmin, vmax calculations
Used for vh, vmin, vmax calculations
CSS Unit Guide
px: Pixels, most common for precise control
pt: Points (1/72 inch), used in print
in, cm, mm: Physical measurements
rem: Relative to root font size (best for scaling)
em: Relative to parent font size
%: Percentage of parent element
ch: Width of "0" character
vw/vh: 1% of viewport width/height
vmin/vmax: 1% of smaller/larger viewport dimension
vi/vb: Inline/block axis (writing mode aware)
cqw/cqh: 1% of container width/height
cqi/cqb: 1% of container inline/block size
Modern units for container-based responsive design