About Border Radius Generator
The border-radius property rounds the corners of an element. One value rounds all four corners equally, two values set the top-left/bottom-right and top-right/bottom-left pairs, and four values set each corner in clockwise order starting at the top left.
Type one to four numbers or lengths and the tool writes the declaration, adding px to plain numbers. You can also use percentages: 50% on a square element makes a circle. Copy the line into your stylesheet.
How to use Border Radius Generator
- Type one to four values, for example 12 or 16 16 0 0.
- Click Run Tool to generate the declaration.
- Copy the result into your CSS.
Example
Input
16 16 0 0
Output
border-radius: 16px 16px 0px 0px;
Common uses
- Making a card with rounded top corners only.
- Turning a square image into a circle with 50 percent.
- Creating pill-shaped buttons with a large radius.
Privacy and safety
This tool runs in your browser. The text you enter is processed on your device and is not sent to NHP Learning.
Frequently asked questions
In which order are four values applied?
Top-left, top-right, bottom-right and bottom-left, which is clockwise from the top-left corner.
How do I make a circle?
Use a square element and set border-radius to 50%.
Can I use rem or percentages?
Yes. Values that already include px, %, rem or em are kept as you typed them.