CSS Border Radius Generator
Round each corner on its own — or flip to blob mode and shape the organic, wobbly outlines used for avatars, hero art, and badges. The preview block reshapes as you slide, and the code underneath is the exact border-radius declaration to paste into your stylesheet.
Private by construction: everything is computed in your browser — nothing is uploaded or logged.
Corners: one radius per corner. Blob: the eight-percentage fancy radius for organic shapes.
Your CSS
border-radius: 16pxPrivate by construction: every value is turned into CSS in your browser — nothing is uploaded, sent, or logged.
Embed this calculator on your website →
The formula
border-radius: top-left top-right bottom-right bottom-left
- the shorthand shortens itself — when all four corners match, one value prints (16px). When opposite corners match in pairs, two print; when the two side corners match, three. The tool applies the same reduction the CSS specification defines, comparing each corner as a value-and-unit pair.
- px or % — pixels are absolute; percentages resolve against the box's width (horizontal radius) and height (vertical radius), so 50% on a square makes a circle and on a rectangle an ellipse.
- the slash form — corners can carry separate horizontal and vertical radii: border-radius: 10px / 20px reads "10 across, 20 down" for every corner.
- blob mode — the eight-value fancy radius: four horizontal percentages, a slash, four vertical ones. Nothing is shortened there — the pattern is the point.
Worked examples: all corners at 16px print border-radius: 16px; the classic blob 30% 70% 70% 30% / 30% 30% 70% 70% leans the shape down-right.
How it works
Every corner is a quarter ellipse. A corner radius is really two numbers — how far the curve reaches along the top edge and how far down the side. The one-value shorthand just sets both to the same number; the slash form lets them differ, which is how pill ends and leaf shapes are made.
Why blobs wobble. In blob mode each side's curve is placed by percentages that do not mirror each other, so no corner is a neat quarter circle. Animating between two blob values is a popular way to make shapes slowly morph — both endpoints must keep the full eight-value form, which is why this tool never shortens it.
Oversized radii are safe. Asking for more radius than a side can fit is legal CSS: the browser scales all corners down proportionally so they never overlap. 9999px is the traditional "full pill" idiom for exactly that reason.
Examples
- A perfect circle — a square element with every corner at 50%: border-radius: 50%
- A leaf — two opposite corners large, two at zero: border-radius: 0px 24px 0px 24px (top-left and bottom-right paired at 0, the other pair at 24 — so the two-value shorthand prints).
- An arch — top corners at 50%, bottom corners square: border-radius: 50% 50% 0% 0%
Frequently asked questions
Why did four values turn into two in the output?
The CSS shorthand reduction: when top-left equals bottom-right and top-right equals bottom-left, the two-value form means exactly the same thing, so the tool prints the shorter canonical code. Your corners are unchanged.
What is the difference between 16px and 16%?
Pixels are fixed: a 16px radius looks the same on a button and a banner. Percentages scale with the box — and on non-square boxes the horizontal and vertical radii resolve against different sides, which is what makes 50% an ellipse rather than a circle there.
Can a radius be too big?
No — browsers proportionally shrink all radii when they would overlap, so large values are safe. Designers use very large values like 9999px to guarantee a fully rounded pill on elements of any size.
Why doesn't blob mode shorten its output?
Blob animations interpolate between two eight-value shapes; shortening either endpoint breaks the interpolation pairing. The full form is also the convention every blob reference uses, so the tool keeps it intact.
Related calculators
CSS Box Shadow Generator
LiveLayer soft or hard box shadows with offsets, blur, spread, inset, and color opacity — live preview and copy-ready CSS.
CSS Gradient Generator
LiveBuild linear, radial, and conic CSS gradients with multiple color stops — live preview and copy-ready background code.
Color Converter
LiveConvert colors between HEX, RGB, and HSL with a live swatch — the standard CSS color formulas, with the rounding rules stated.

