clamp() calculator
Calculate the ideal viewport-based font size using the clamp() CSS function.
Used for calculation if you work in REM.
Responsive Typography
Resize your browser window width to see the effect.
Current window width: px
Calculated size:
Current window width: px
Calculated size:
Features
- Calculate perfect fluid typography using CSS clamp().
- Support for PX and REM units.
- Real-time preview of the font scaling.
- Customizable root font size for REM calculations.
- Copy-paste ready CSS snippet.
How to Use
- Select your preferred unit (Pixels or REM).
- Enter the minimum and maximum viewport widths (e.g., 320px to 1200px).
- Enter the minimum and maximum font sizes you want at those widths.
- Copy the generated
font-size: clamp(...)code.