CSS scroll-padding-block-end Property
Description
The scroll-padding-block-end property adjusts the scroll container’s logical “end” inset along the block axis so that the browser treats the scroll snapport (the area used for snapping and alignment) as if it were smaller by that inset at the block end. In practical terms, it moves the effective stopping point away from the container edge on the block-end side so scrolled or snapped items align with that inset rather than flush with the container edge. Its effect follows the block axis defined by the element’s writing mode and text direction, so the physical edge that corresponds to “block end” depends on the container’s writing-mode/flow.
This property is primarily used to create reserved space for UI elements (for example sticky headers or overlays) without changing layout geometry. By adding an inset on the block end, you can prevent snapped or programmatically scrolled-to content from being hidden behind such overlays: items will stop earlier and remain visible below the overlay. It works together with container-level scroll padding controls like scroll-padding and the axis-specific shorthand scroll-padding-block, letting you target only the block-end side when you need asymmetric insets.
Note that scroll-padding-block-end only affects the scrollport used for snapping and alignment — it does not alter the element’s layout dimensions or create visual spacing the way ordinary box padding or margins do. For per-item adjustments that affect how an individual element is positioned into view, use the child-focused property scroll-margin. And to control how a particular item lines up with the adjusted snapport (start, center, end), you combine container insets with each item’s alignment setting such as scroll-snap-align.
Because it is a logical property, scroll-padding-block-end is especially helpful in internationalized layouts: a single declaration adapts to different writing modes and directions without requiring separate physical-side rules. Use it when you need predictable snap and scroll alignment behavior that respects overlays and different block-flow orientations while keeping layout and box metrics unchanged.
Definition
- Initial value
- auto
- Applies to
- scroll containers
- Inherited
- no
- Computed value
- as specified
- Animatable
- by computed value type
- JavaScript syntax
- object.style.scrollPaddingBlockEnd
Interactive Demo
Syntax
scroll-padding-block-end: auto | <length-percentage [0,∞]>
Values
- autoThe offset is determined by the user agent. This will generally be 0px, but a user agent is able 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-block-end 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
