Visit homepage

CSS overscroll-behavior

  • Planted:

To control scroll behavior when reaching the boundary of a scrolling area, use overscroll-behavior.

styles.css

body {
overscroll-behavior: auto; /* default */
overscroll-behavior: contain;
overscroll-behavior: none;
}

I used overscroll-behavior: none; to prevent pull-to-refresh behavior on mobile browsers for my edison bulb night mode.

As of 2023, it is well-supported in browsers.

Backlinks

Reply