Skip to main content

Free CSS Border Radius Generator

Visually design rounded corners with independent control over each corner. Supports the elliptical X/Y syntax for organic blob shapes.

Works offline once loaded
border-radius: 20px 20px 20px 20px;
Unit

Common uses

  • Organic Blob ShapesUse the elliptical X/Y syntax to create unique blob shapes for hero sections and illustrations.
  • Card and Container CornersStandard rounded corners for cards, containers, and panels in modern UI design.
  • Avatar & Profile Picture ShapesCreate the right corner style for profile pictures: circular, squircle, or rounded square.
  • Pills, Tags, and BadgesBuild perfectly rounded pill buttons, tags, and badges with the 9999 preset.
  • Asymmetric Corner DesignsMix radii across corners to create distinctive, brand-recognizable card and button shapes.

How It Works

The border-radius generator runs entirely in the browser β€” there is no server, no library, and no upload. It builds the CSS border-radius value string directly in JavaScript using React state and useMemo, then applies it as an inline style on a live div element so the browser's own CSS engine renders the shape in real time.

  1. 1
    Sliders write state
    Each range input writes to one of eight numeric state variables β€” four horizontal corner radii and four vertical ones for elliptical mode. Unified mode collapses all eight into a single slider via a setAll helper that synchronises every value at once.
  2. 2
    useMemo assembles the CSS value
    A useMemo hook recomputes the border-radius string whenever any corner value, unit (px or %), or elliptical toggle changes. In standard mode it produces the four-value shorthand; with elliptical on, it adds the slash separator for the full eight-value syntax β€” e.g. 32px 20px 20px 32px / 20px 32px 20px 32px.
  3. 3
    Browser CSS engine renders the preview
    The computed string is set as an inline borderRadius style on a plain div element. The browser's layout engine does all the rendering β€” there is no canvas, no SVG, and no third-party drawing code.
  4. 4
    Clipboard API copies the output
    Clicking Copy calls navigator.clipboard.writeText with either the CSS declaration (border-radius: ...;) or the equivalent Tailwind arbitrary-value class (rounded-[...]), depending on the selected format toggle.

Related Tools

Frequently Asked Questions