Favorite places of your favorite city
Home
Add to preferred sources on Google

CSS Border Radius Generator

Shape an empty CSS box with independent horizontal and vertical corner radii. Mix pixels and percentages, choose preview dimensions, and copy the authored declaration rather than rounded diagnostic pixels.

Preview

Fit · 240 × 120 CSS px

Corner settings

Use a decimal point or comma, for example 0.5 or 0,5. Unit changes keep the number.

1–2000 px

1–2000 px

Top left

Top right

Bottom right

Bottom left

Generated CSS

240 × 120 CSS px · f = 1. No overlap scaling is needed.

Horizontal percentages use width; vertical percentages use height. A zero component makes its corner square. Rounded diagnostic pixels are not exported.

How these corners fit
  • Percentage bases: 240 px wide × 120 px high
  • Common scale factor: 1

Edge fit

Top edge

20 + 20 = 40 px · Available: 240 px

Right edge

20 + 20 = 40 px · Available: 120 px

Bottom edge

20 + 20 = 40 px · Available: 240 px

Left edge

20 + 20 = 40 px · Available: 120 px

Corner radii

ResolvedUsed
Top left20 × 20 px20 × 20 px
Top right20 × 20 px20 × 20 px
Bottom right20 × 20 px20 × 20 px
Bottom left20 × 20 px20 × 20 px

Settings stay in this browser; copying happens only when you choose it.

Build a corner shape in three steps

  1. Set box width and height from 1 to 2000 CSS pixels. Enter each corner’s horizontal and vertical radius in px or %, or apply the top-left pair to all corners.
  2. Inspect the fit preview. Horizontal percentages use box width, vertical percentages use height; changing a unit keeps the number and changes its meaning.
  3. Choose Radius only or Box CSS and copy the complete displayed result. If Copy is unavailable, select the readonly text. Invalid fields have no current CSS result.

Read the two radii at each corner

A corner has a horizontal and a vertical radius. The slash in border-radius separates four horizontal values from four vertical values, both ordered top-left, top-right, bottom-right, bottom-left.

Percentages use different bases: width for horizontal radii and height for vertical radii. On a rectangular box, 50% in both directions makes an ellipse, not necessarily a circle. A zero component makes that corner square.

When adjacent radii overlap an edge, the browser scales all eight components by one common factor. The method shows resolved and used pixels for this preview box; those rounded explanations do not replace authored CSS.

The preview lays out your declared box before fitting the whole shape into the available space. Radius-only CSS can behave differently on a differently sized receiving box. Box CSS also supplies dimensions, border-box sizing, zero border and zero padding; preview colors are not included.

Useful mixed-unit examples

On a 240 by 120 box, horizontal values 75%, 120px, 20%, 30px and vertical values 40px, 60%, 60px, 50% produce a common factor of 0.8. The top horizontal radii become 144px and 96px, while every other component is scaled too.

Keep those authored values but change the box to 120 by 240. The limiting factor becomes 4/7, so the used shape changes without rewriting your percentages into fixed pixels.

A 240 by 120 box with 50% horizontal and vertical radii uses 120px and 60px. All zero radii instead leave square corners; neither case needs a separate image editor.

Scope and interpretation

This numeric editor supports nonnegative px radii up to 4000 and percentages up to 1000, with at most three decimal places. It does not parse arbitrary CSS, calc(), var(), logical corners or other units.

Use one decimal point or comma, without grouping separators. A unit change keeps the entered number, not the old resolved length. Blank, partial, out-of-range or otherwise invalid fields disable the current preview and Copy instead of showing stale CSS.

Used-pixel and factor displays are rounded explanations for the declared preview box. Native rendering can use subpixel rounding; copied CSS retains your canonical authored values and units.

The fit percentage changes only how the preview is displayed. It does not change the logical box or the exported rule. On another box, percentages and overlap scaling are recalculated by that browser.

Border radius shapes a background or border; it does not universally clip children or make a complete component. This tool adds no uploaded image, drag editor, animation, layout framework or overflow rule.

Local styling without saved drafts

The tool adds no upload, saved history, input-bearing link or request containing your settings. Clipboard access is explicit. Existing site services, browser extensions and copies you keep are outside any universal privacy or erasure promise.

Corner styling questions

Each of four physical corners has a horizontal and a vertical radius. Equal values make circular arcs in pixels; different values allow elliptical corners. The slash keeps the two groups separate.

A horizontal percentage uses the border-box width, while a vertical percentage uses its height. Changing either dimension can change used geometry even when the authored declaration stays the same.

Adjacent corners cannot overlap an edge. The browser resolves units, finds the limiting side and scales all eight components by one shared factor. It does not independently cap every radius at 50%.

Usually no. Copy uses the authored CSS, including responsive percentages. Used pixels are rounded diagnostics for this box, and re-exporting them can change the intended behavior or introduce another overlap.

No. The number is retained and its unit changes, so its meaning may change immediately. This avoids a hidden conversion based on one preview size; the new geometry is shown explicitly.

It adds border-box sizing, your width and height, zero border and zero padding before the same radius declaration. It does not include the preview background, outline, HTML or a complete design system.

Not by itself in every case. Child overflow and image clipping depend on other CSS. This generator does not silently add overflow:hidden or claim to solve those separate behaviors.

The tool adds no upload, saved draft history or settings-bearing request. Copy happens only on your action. Browser extensions, existing site services and any copies you keep are not covered by a universal privacy promise.

Sources

The specification defines the geometry used by this editor.

Reviewed 12 November 2026.

Diagnostics describe the specification; actual rendering may vary with browser subpixel rounding.

SVG to PNG

Convert a local SVG file or pasted markup into PNG, with explicit dimensions, transparency and bundled fonts.

Open tool — SVG to PNG

CSS Filter Generator

Order and repeat CSS effects, compare a specimen and copy the exact filter declaration.

Open tool — CSS Filter Generator

Fluid Font Size Calculator

Create root-relative CSS from viewport endpoints and inspect the copied size model.

Open tool — Fluid Font Size Calculator

CSS Button Generator

Style native button states, inspect keyboard focus and copy HTML and CSS.

Open tool — CSS Button Generator

CSS Grid Generator

Build a bounded CSS Grid example with editable tracks, placement and named areas. Preview it, copy CSS or HTML and download the same standalone example.

Open tool — CSS Grid Generator

CSS Flexbox Generator

Build a Flexbox example with container and item controls, explicit layout axes, matching CSS and HTML, and a local complete-example download.

Open tool — CSS Flexbox Generator

CSS Text Shadow Generator

Build ordered text shadows, preview plain text and copy exact CSS.

Open tool — CSS Text Shadow Generator

CSS Transform Generator

Compose repeatable 2D CSS transforms, edit px or percentage translation and origin, inspect a reference box and copy the exact current declarations.

Open tool — CSS Transform Generator

CSS Box Shadow Generator

Create ordered CSS box-shadow layers with a live preview and copyable code.

Open tool — CSS Box Shadow Generator

Image Watermark

Add a text or logo watermark to a batch of images, review each result and download individual files or a ZIP.

Open tool — Image Watermark

CSS Gradient Generator

Create linear or radial CSS gradients with editable colors, opacity and stops.

Open tool — CSS Gradient Generator

Color Converter

Convert supported sRGB HEX, RGB and HSL literals with alpha, explicit precision and current code Copy.

Open tool — Color Converter

Image to Text (OCR)

Recognize printed text in local PNG or JPEG images, choose a language and review or correct the result before copying or downloading.

Open tool — Image to Text (OCR)

QR Code Reader

Read one QR code from a local PNG or JPEG and inspect its text or content bytes without opening links.

Open tool — QR Code Reader

Color Contrast Checker

Compare foreground and background colors, adjust opacity and check WCAG numerical contrast thresholds for text and essential interface details.

Open tool — Color Contrast Checker

Print Size & Resolution Calculator

Calculate print dimensions, required pixels and effective PPI with fit or crop.

Open tool — Print Size & Resolution Calculator

Aspect Ratio Calculator

Find a width-to-height ratio or calculate a matching pixel size from one target dimension.

Open tool — Aspect Ratio Calculator

Image Compressor

Try to fit a JPEG, PNG or WebP within a target file size, with measured results and optional smaller dimensions.

Open tool — Image Compressor

HEIC to JPG

Convert supported HEIC photos locally into full-size JPG copies, with quality and background controls and verified individual or ZIP downloads.

Open tool — HEIC to JPG

Image Converter

Convert supported PNG, JPEG and WebP images locally with batch targets, transparency, background and quality controls, then review and download the encoded files.

Open tool — Image Converter

Photo Collage Maker

Arrange local photos in a grid, adjust crops and spacing, and download PNG or JPEG.

Open tool — Photo Collage Maker

Rotate & Flip Images

Rotate or mirror a local batch of static PNG, JPEG and WebP images, then review and download the processed results.

Open tool — Rotate & Flip Images

Image Cropper

Crop one local JPEG, PNG or WebP to exact pixels with visual and numeric controls. Download PNG or JPEG.

Open tool — Image Cropper

Image Resizer

Resize a JPG, PNG or WebP image by pixels or percentage, preview the result and download it.

Open tool — Image Resizer
View all tools in this category