Disable Scrolling
Prevent the page from scrolling in Webflow when an element is clicked or an element is visible on the page.

Implement in Webflow
Apply attributes to elements on the page
Below is a list of elements and options that are used to create this Attributes functionality. Click any of them to see more details.
Button, Text Link, Link Block, or Div Block

Button, Text Link, Link Block, or Div Block

Button, Text Link, Link Block, or Div Block

Div Block or any element
Important: This element must be the affected by interactions/CSS classes to be displayed/hidden. We will watch when this element is set to display none and apply scrolldisable when this element is not set to display none.


Div Block, Rich Text Block or Section
In some devices (especially iOS), users might not be able to scroll in scrollable elements when the page scrolling is disabled.
If you want to prevent this behavior, you can disable it by setting it to false.
Examples:
fs-scrolldisable-media = "(max-width: 478px)"
fs-scrolldisable-media = "(min-width: 992px)"
fs-scrolldisable-media = "(min-width: 478px) and (max-width: 1920px)"
Working examples
See this solution working live in this Webflow project.
Frequently Asked Questions
Everything you need to know about this attributes solution.