What Is Responsive Typography?
Responsive typography automatically scales font sizes between a minimum and maximum value based on the viewport width. Instead of setting fixed font sizes that are too small on mobile or too large on desktop, responsive type fluidly adapts to every screen size using CSS clamp() functions and viewport units.
This calculator generates the exact CSS clamp() values you need. Define your minimum font size (for mobile), maximum font size (for desktop), and the viewport range over which scaling should occur. The tool outputs production-ready CSS that smoothly interpolates between your bounds — no media queries, no JavaScript, no breakpoint jumps.
How to Use This Tool
- Set your minimum font size — This is the smallest the text should ever be — typically the size you want on mobile screens (320–375px wide). Common values: 16px for body text, 24px for headings.
- Set your maximum font size — This is the largest the text should be — the size on wide desktop screens (1200–1440px). Common values: 18–20px for body, 48–64px for hero headings.
- Define the viewport range — Set the minimum viewport width (usually 320–400px) and maximum viewport width (usually 1200–1440px) over which the scaling occurs.
- Copy the CSS clamp() output — The tool generates a CSS clamp() function that you paste directly into your stylesheet. It handles all the math — preferred value, viewport units, and clamping bounds.
Worked example: the default scale, measured, and what browser zoom does to it
With the defaults (body 16 → 20 px from a 320 to a 1440 px viewport, ratio 1.25, six steps), the tool writes --font-base: clamp(1.000rem, 0.9286rem + 0.3571vw, 1.250rem), plus five more steps. We applied all six in Chromium 141 on October 12, 2026 at four viewport widths and read the computed sizes:
| Step | 320 px | 576 px | 720 px | 1440 px |
|---|---|---|---|---|
| xs | 10.24 | 10.83 | 11.15 | 12.80 |
| sm | 12.80 | 13.53 | 13.94 | 16.00 |
| base | 16.00 | 16.91 | 17.43 | 20.00 |
| lg | 20.00 | 21.14 | 21.79 | 24.99 |
| xl | 25.00 | 26.43 | 27.23 | 31.25 |
| 2xl | 31.25 | 33.04 | 34.04 | 39.06 |
Two things to check before you ship a scale.
The bottom steps can get very small. The ratio is applied below the base too, so xs comes out at 10.24 px on a phone. WCAG doesn't set a minimum font size (there's no "16 px rule"), but 10 px is small enough that you may want to raise the minimum base or use fewer steps below it.
Zoom grows fluid text less than you'd expect. Browser zoom shrinks the viewport in CSS pixels, so the vw part of the formula gets smaller as you zoom in. On a 1440 px window, 200% zoom puts the layout at 720 CSS px. Every step then renders at 2 × its 720 px size, which is 1.74 times its 100% size rather than 2 times. You need about 250% zoom to reach double size (2.11× measured). WCAG 2.2's success criterion 1.4.4 (Resize Text) asks that text can be resized up to 200%. Browsers zoom well beyond 250%, so this scale can still get there. A steeper range (a bigger gap between minimum and maximum) pushes the zoom needed higher, though. Keep the gap modest, and test the result with browser zoom at 200%.
Keep the unit on rem, the default, rather than px. Rem-based minimums and maximums grow when a reader raises their browser's default font size, and px values ignore that setting. clamp() itself is supported in Chrome and Edge 79, Firefox 75 and Safari 13.1, according to MDN's compatibility data. The tool outputs no fallback, which isn't needed in current browsers.
Sources
Checked on .
Related tools
- Fluid type means line lengths change with viewport. The Hyphenation Tester lets you preview text-wrap balance and hyphens auto at any column width.
Frequently Asked Questions
📖 Learn More
Related Article How to Build a Typography Scale → Related Article Font Pairing Guide for Web Designers →Built by Derek Giordano · Part of Ultimate Design Tools