Skip to content

Rounded Corners

Border radius

  • Lesson
  • 1 min read
  • 7 of 8 in this chapter

The border-radius property can be used to add rounded corners to an element. Even if there isn't a border property specifying the border width/style, adding border-radius will still round the corners of the background.

CSS
p {
    width: 200px;
    height: 300px;
    background-color: pink;
    border-radius: 10px;
}