CSS scroll-padding-bottom Property
Description
The scroll-padding-bottom property controls the bottom inset of a scroll container’s snapport — the visible region used by the scroll snapping algorithm — by reserving extra space at the container’s bottom for alignment purposes. It does not change the layout or box model of the content itself; instead it shifts where snap positions and target elements are considered “aligned” relative to the viewport of the scroll container. In practice, this means the final position an element snaps to can be offset upward from the physical bottom edge of the container so that content isn’t flush against or hidden by other UI elements.
When you use CSS scroll snapping, the reserved scroll padding interacts directly with the snapping algorithm so that elements with snap points land at a comfortable visual offset. This is useful when combined with properties that enable snapping behavior such as scroll-snap-type and when defining per-element alignment with scroll-snap-align. By adjusting the bottom inset you can ensure snapped items align where you expect visually without altering the element’s own margins or position.
It’s important to distinguish scroll-padding-bottom from layout padding: the regular padding-bottom changes the box model and the space inside the element, while scroll-padding-bottom only changes how the scroll container treats the endpoint for snapping and scroll-position calculations. If you prefer to work with logical properties that adapt to writing modes, the equivalent logical control is available via scroll-padding-block-end, which will map to the appropriate side in vertical or horizontal writing modes.
Typical use cases include offsets for sticky footers or UI chrome so that snapped content isn't obscured, creating breathing room at the end of a list when snapping items to view, and fine-tuning the user experience of paged or carousel-like scroll containers. Because it only affects how the scroll port interprets snap positions, you can use it alongside layout positioning (for example, elements positioned with position) or smooth scrolling behavior to craft a predictable and polished scroll interaction without altering content sizing.
Definition
- Initial value
- auto
- Applies to
- scroll containers
- Inherited
- no
- Computed value
- as specified
- Animatable
- by computed value type
- JavaScript syntax
- object.style.scrollPaddingBottom
Interactive Demo
Syntax
scroll-padding-bottom: auto | <length-percentage [0,∞]>>
Values
- autoThe offset is determined by the user agent. This will generally be 0px, but the user agent is free to detect and do something else if a non-zero value is more appropriate.
- <length-percentage>An inwards offset from the corresponding edge of the scrollport, as a valid <length> or a <percentage>.
Example
Browser Support
The following information will show you the current browser support for the CSS scroll-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
Tablets & Mobile
Last updated by CSSPortal on: 1st January 2026
