Skip to content
I Hate Online Tools

CSS clamp calculator

Fluid type/spacing: clamp(min, preferred, max) from viewport range.

Runs in this tab. The file stays here.

Preview

Fluid type sample

CSS
font-size: clamp(16px, 3.6364vw + 4.3636px, 48px);

This runs in your browser. Nothing is uploaded.

About CSS clamp calculator

Generate a fluid clamp() from min/max values and viewport range.

Generate a fluid clamp() from min/max values and viewport range.

Everything runs in this tab. Copy the CSS when you are happy with the preview.

How to use CSS clamp calculator

  1. 1Adjust the controls.
  2. 2Watch the live preview.
  3. 3Copy the generated CSS.

Common questions

Does this inject styles into my site?

No. It only shows preview CSS here. You paste the output into your own stylesheet.

Related tools

Why this one doesn't upload your file

There is no server to upload to. This page is a static file, and the work happens in your browser using the same graphics and WebAssembly code that renders every other site you visit. Your file is read from disk into memory, processed, and handed back as a download. Once the page has loaded you can disconnect from the network entirely and it keeps working. The longer explanation

Install the app