Padding

noun

say it: “PAD-ing” /ˈpædɪŋ/

The space inside an element, between its content and its border.

What is padding in CSS?

Padding is the space inside an element, between its content and its border.

.button { padding: 10px 20px; }   /* 10px top/bottom, 20px left/right */

In a sentence

  • “Some padding keeps the button's text away from its edges.”

Level: Novice · More CSS terms at this level

Updated