Generating the CSS
Decide on linked corners
While the corners are linked, moving one slider changes every corner together. Unlink them when a design needs a different curve on each corner.
Choose the unit
Pixels (0 to 150) for a fixed curve; Percent (0 to 50) for a curve that scales with the element.
Drag or use a preset
Pill, Circle, Card and Sharp set common values in one click.
Copy the rule
The CSS box shows the finished
border-radiusdeclaration ready to copy.
Example: a card with only its top corners rounded
A web designer building a pricing section for a local gym wants each card's coloured header to have rounded top corners and a square bottom where it meets the card body.
Unticking Same for all corners, setting Top left and Top right to 12 and both bottom corners to 0 produces the rule below. The four values run clockwise from the top left.
Top left 12, Top right 12, Bottom right 0, Bottom left 0, Pixels
border-radius: 12px 12px 0 0;
What the presets produce
| Preset | CSS | Shape |
|---|---|---|
| Pill | border-radius: 9999px; | Fully round ends on buttons and tags of any width |
| Circle | border-radius: 50%; | A circle on a square element, an oval on a rectangle |
| Card | border-radius: 16px; | Softly rounded panels and cards |
| Sharp | border-radius: 0; | Square corners |
Pixels or percent?
Pixel values keep the same curve whatever the element's size, which gives a consistent look across buttons and cards. Percentages are relative to the element's own width and height, so 50% on a wide box makes an ellipse rather than rounded ends. For a pill button, the very large pixel value used by the Pill preset is the reliable choice.
If you are styling HTML emails, test in the email programs your customers use: some ignore border-radius, so the corners simply show square there.
Questions people ask
How do I round only some corners in CSS?
Give border-radius four values, which apply clockwise from the top left: top left, top right, bottom right, bottom left. Untick Same for all corners here, set each slider, and copy the generated line, for example 12px 12px 0 0 for rounded top corners only.
How do I make a circle with CSS?
Give the element equal width and height and set border-radius to 50%. The Circle preset here switches the unit to percent and sets every corner to 50. On a rectangle the same value produces an oval.
Why use 9999px for a pill shape?
A radius larger than half the element's height is capped by the browser, so a huge value always gives perfectly round ends however tall or wide the button becomes. A percentage would produce an ellipse on a wide button instead.
Where your data goes
The preview and the CSS are produced in your browser. Nothing you set is sent anywhere.
Checked against the tool on