CSS Portal

CSS padding-bottom Property

If this site has been useful, we’d love your support! Consider buying us a coffee to keep things going strong!

Description

The padding-bottom property controls the space between an element's bottom edge of its content area and the inside edge of its bottom border. It is one side of the element’s internal padding and directly increases the distance between the content (text, images, children) and the element’s border on the bottom side. Because padding is part of the element’s box, changing padding-bottom affects the element’s visual rhythm and spacing without creating external separation from neighboring elements the way margins do.

In the box model the padding area is distinct from the border and margin areas; backgrounds are painted into the content and padding areas, so any bottom padding will show the element’s background behind the added space (background). Whether that added padding increases the element’s outside dimensions depends on how sizing is calculated — for example the box sizing model can alter whether padding contributes to the element’s reported width/height (box-sizing). Also note that padding does not participate in collapsing behavior that affects adjoining vertical margins, so adding bottom padding will not collapse with an adjacent margin (margin).

Practically, bottom padding is often adjusted to create breathing room for content, to align elements visually, or to provide space before scrollbars or other overflow behavior; increasing bottom padding will expand the scrollable area when content overflows (overflow). Designers frequently manage all four sides of an element’s internal spacing using the shorthand padding, while still fine-tuning a single side like the bottom with padding-bottom when only that vertical spacing needs to change.

Definition

Initial value
0
Applies to
All elements
Inherited
No
Computed value
<length> - the percentage as specified or the absolute length
Animatable
Yes
JavaScript syntax
object.style.paddingBottom

Interactive Demo

The rusty swing set creaked a lonely lullaby in the twilight, shadows lengthening like grasping fingers across the dew-kissed grass. A lone dandelion seed, adrift on the breeze, whispered secrets of faraway fields, of dandelion suns and galaxies spun from fluff. Somewhere, beyond the veil of dusk, a coyote laughed, echoing through the stillness like a forgotten memory.

Syntax

padding-bottom: [ <length> | <percentage> ]

Values

  • <length>Specifies a positive fixed width.
  • <percentage>A percentage with respect to the width of the containing block.
  • inherit

Example

<div class="example">
<h2>padding-bottom example</h2>
<div class="box">Default padding (16px)</div>
<div class="box with">Increased padding-bottom (48px)</div>
</div>
.example {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
  max-width: 640px;
  margin: 24px auto;
  padding: 16px;
}

.box {
  background-color: #107c10;
  color: #ffffff;
  padding: 16px;
  border-radius: 8px;
  margin-bottom: 12px;
}

.box.with {
  background-color: #0078d4;
  padding-bottom: 48px;
}

Browser Support

The following information will show you the current browser support for the CSS padding-bottom property. Hover over a browser icon to see the version that first introduced support for this CSS property.

This property is supported by all modern browsers.
Desktop
Chrome
Edge
Firefox
Opera
Safari
Tablets & Mobile
Chrome Android
Firefox Android
Opera Android
Safari iOS
Samsung Internet
Android WebView
-

Last updated by CSSPortal on: 1st January 2026

If this site has been useful, we’d love your support! Consider buying us a coffee to keep things going strong!