How can I make a Webflow page automatically scroll 600px down upon load without affecting any elements on the page?

TL;DR
  • Go to page settings in Webflow Designer, click the gear icon, and add a JavaScript snippet in the "Before </body> tag" section to scroll down by 600px on page load.
  • Save changes and publish your site, then verify the scroll effect.

To set a Webflow page to automatically scroll down by 600px upon load, you will need to use custom code in your project settings. Here's how you can achieve this without affecting any page elements:

1. Use Custom Code in Page Settings

  • Go to Page Settings: Navigate to the specific page in the Webflow Designer.
  • Access the Page Settings: Click on the gear icon next to your page name to open settings.
  • Add Custom Code: Scroll to the Before </body> tag section in the Page Settings.

2. Insert JavaScript Snippet

  • Write the JavaScript: Insert the following JavaScript into the Before </body> tag section to automatically scroll the page.

  

  ```plaintext

  <script>

    window.onload = function() {

      window.scrollTo(0, 600);

    };

  </script>

  ```

  

  • Ensure Proper Placement: Place this script tag inside the section mentioned to ensure it executes after the page loads.

3. Publish Your Site

  • Save and Publish: Save the changes in your Page Settings and publish your site to see the effect live.

4. Test the Scroll Function

  • Verify the Scroll Effect: Once your site is published, visit the page to ensure it scrolls down by 600px automatically upon load.

Summary

To achieve an automatic scroll effect of 600px on a Webflow page without affecting other elements, insert a JavaScript snippet into the Before </body> section of your page settings. This will execute the scroll action once the page finishes loading.

Rate this answer

Other Webflow Questions