Visual guide to CSS border-radius: compare different radius values, master individual corners, create circles and organi...
Rounded corners went from a trendy design choice to a fundamental UI element. Every modern operating system, website, and app uses them — from macOS window controls to Instagram profile pictures to the card components in this very article. But getting border-radius right involves more than typing border-radius: 10px. This visual guide shows you exactly what different values produce, how to control individual corners, and how to create shapes that elevate your design from basic to polished. Try everything interactively with our free Border Radius Generator.
Border-radius defines the radius of the quarter-circle (or quarter-ellipse) that rounds each corner. The larger the value, the more dramatic the curve. Here's how different values transform a 200×200px square:
The jump from 0px to even 4px makes a surprising difference in perceived quality. Sharp corners feel technical and cold; rounded corners feel human and approachable. Most design systems default to 8px or 12px for this reason.
You don't have to apply the same radius to every corner. CSS gives you granular control through shorthand and individual properties:
border-radius: 20px 0 20px 0;
This creates alternating rounded and sharp corners — the top-left and bottom-right are rounded at 20px, while top-right and bottom-left remain sharp. This diagonal pattern is popular for quote blocks and callout elements.
border-top-left-radius: 20px; border-top-right-radius: 0; border-bottom-right-radius: 20px; border-bottom-left-radius: 0;
border-radius: 16px 16px 0 0 — Great for tab headers, dropdown menus, and card topsborder-radius: 0 0 16px 16px — Perfect for sticky footers and notification bannersborder-radius: 16px 0 0 16px — Used for sidebar elements and left-aligned badgesborder-radius: 0 16px 16px 0 — Common for right-aligned pills and trailing indicatorsborder-radius: 20px 0 20px 0 — Creates a distinctive angular feel for feature blocksWhen you set border-radius to 50% on a square element, the result is a perfect circle. This is the standard technique for circular avatars, icons, and profile pictures:
width: 120px; height: 120px; border-radius: 50%; overflow: hidden;
On a rectangular element, 50% creates an oval (stadium shape). A 200×80px element with border-radius: 40px (half the height) becomes a pill shape — a common pattern for buttons, tags, and notification badges.
The key insight: for a perfect pill, set border-radius to half the shorter dimension. For a 200×80px element, use 40px. This ensures the ends are perfectly semicircular regardless of the element's width.
For truly organic shapes, CSS supports separate horizontal and vertical radii using slash-separated values:
border-radius: 80px / 20px;
This creates corners that are wide horizontally (80px) but shallow vertically (20px), producing a subtle curve that looks elegant on larger containers. The value before the slash controls the horizontal radius, and the value after controls the vertical radius.
You can also set different elliptical values for each corner:
border-radius: 80px 20px 80px 20px / 40px 40px 40px 40px;
This pattern creates an egg-like or leaf-like shape, useful for creative backgrounds, decorative elements, and unique card designs that stand out from template-looking layouts.
Border-radius isn't limited to gentle curves. By combining different values, you can create surprisingly complex shapes:
border-radius: 0 50% 0 50% — Creates a diagonal leaf or diamond-rounded-corner shapeborder-radius: 50% 0 50% 50% — A rounded shape with one sharp corner, like a speech bubble tailborder-radius: 30% 70% 70% 30% / 30% 30% 70% 70% — An organic, amoeba-like form popular in modern illustrationsborder-radius: 50% 0 50% 0 — Creates a quadrant-rounded shapeThese shapes are increasingly popular in modern web design, especially for hero sections, feature illustrations, and background decorations. They break the rigid box aesthetic while remaining pure CSS — no SVG required.
Visualize and experiment with border-radius in real time. Our free Border Radius Generator lets you adjust every corner, preview the shape, and copy production-ready CSS code instantly.
Border-radius is deceptively powerful. What starts as a simple rounding property can create circles, pills, ellipses, organic blobs, and unique shapes — all without images or complex markup. By understanding how values map to visual output, mastering individual corner control, and applying consistent design patterns, you can create interfaces that feel polished, modern, and intentional.
Stop guessing values in your CSS. Use our Border Radius Generator to see results in real time and copy the exact CSS you need.