CSS Clamp Generator
Build a single CSS clamp() value that scales a font size (or any length) smoothly between two screen widths. No media queries, no JavaScript. The size locks to your min and max outside the viewport range.
clamp(1rem, 0.8333rem + 0.8333vw, 1.5rem)font-size: clamp(1rem, 0.8333rem + 0.8333vw, 1.5rem);| Viewport | Size | rem |
|---|---|---|
| 320px | 16px | 1rem |
| 480px | 17.3333px | 1.0833rem |
| 768px | 19.7333px | 1.2333rem |
| 1024px | 21.8667px | 1.3667rem |
| 1280px | 24px | 1.5rem |
| 1440px | 24px | 1.5rem |