← TechnologyThe essentials of

border-radius: 50% does not always create a circle

Publisher: ResumeMaker • 1 source

Published: 22 Oct 2026 13:13 · Updated: 22 Oct 2026 13:13

AI source check: 21 Oct 2026 13:48. This is not editorial approval.

In a few sentences

In brief

The shape also depends on the ratio between width and height.

Useful to know

border-radius rounds the corners of the box. At percentage values, the horizontal radius refers to the width, and the vertical - to the height. Therefore, 50% on a rectangle gives an ellipse. [1]

For a circular avatar, the example is width: 80px; height: 80px; border-radius: 50%; object-fit: cover;. Equal dimensions are the essential part. Rounding itself does not select the framing of the picture and does not eliminate the need for meaningful alternative text. With a button, the oblong shape may be a result sought, not an error.

Sources

For further detail and to check the information:

  1. [1] MDN — border-radius ↗