Border Radius Generator
Generate CSS border-radius values.
About this tool
Enter a radius in pixels and get the value to use in border-radius for all four corners. It outputs the value only, such as 8px, not the full declaration.
How to use
How it works
A single value in border-radius applies to every corner. The tool returns that value with a px unit. For different corners write up to four values in the order top-left, top-right, bottom-right, bottom-left, or use 50% on a square element for a circle.
Worked example
A card radius
- Input
- 8
- Output
- 8px
- Walkthrough
- border-radius: 8px; rounds all four corners equally.
Limitations
- One value for all corners; per-corner and elliptical radii are not generated.
- Pixels only.
Questions
How do I round corners with CSS?
How do I make a circle?
Can I set different radii per corner?
Does it give the full CSS declaration?
Features
- Single radius value
- Copy-ready
- Runs in your browser
Related resources
Guides and videos from around the web—opens on YouTube or the publisher’s site.
Learn JSON - Full Crash Course
freeCodeCamp.org
JSON is the payload format behind many developer tools here.
Watch on YouTubeTypeScript in 100 Seconds
Fireship
Typed JS snippets often get formatted or hashed nearby.
Watch on YouTube
- Introducing JSON
json.org
Canonical JSON grammar for formatters and validators.
- Regular expressions
MDN
JS regex guide aligned with browser-based testers.