CSS border-radius generator
This tool rounds the corners of an element and gives you the exact border-radius value to paste into your stylesheet. It is for developers and designers shaping buttons, cards, avatars and pills who want precise, copy-ready CSS. The preview shows a live box that reshapes as you drag.
How it works
The border-radius property accepts either a single value applied to all corners or up to four values written clockwise from the top-left: top-left, top-right, bottom-right, bottom-left. With Link all corners on, moving any slider sets all four equally. With it off, each corner gets its own value. The generator detects when all four match and collapses the output to the shorthand single value; otherwise it writes all four in clockwise order.
Example
With all corners linked at 16px, the output collapses to:
border-radius: 16px;
Unlink and set top-left and top-right to 16px while leaving the bottom corners at 0px, and it becomes border-radius: 16px 16px 0px 0px; — a tab or card-header shape.
| Goal | Value |
|---|---|
| Subtle rounding | 8px |
| Card | 16px |
| Pill (wide element) | 9999px |
| Circle (square element) | 50% |
| Top corners only | 16px 16px 0px 0px |
The border-radius value is generated locally in your browser — nothing is uploaded.