Developers

How to Make Your Top Menu Disappear on Scroll

How to Make Your Top Menu Disappear on Scroll

Create an un-sticky Top Bar using Layout & Design tool

Depending on how you structure your content, it can be helpful to have your site's header and menu bar disappear as readers scroll. We call this un-sticky Top Bar behavior . Here's an example of what this looks like:


This feature can be added set up in our Layout & Design tool using the Show On Scroll element. Once it's in place, you need to create a placeholder top navigation menu that readers will not be able to see.

First, place all items contained by the Navbar element within an Element Wrapper .



Then place the Element Wrapper inside the Show On Scroll element:


Next, create a fake header as an Element Wrapper . Set it to the same height as the Top Bar for each viewport. (e.g., height: 60px; margin: 0;)

It's a good idea to assign it a Friendly Name so you can differentiate it, such as "Navbar Dummy Placeholder."

Here's an example of how the fake header appears in developer view:

Using a dummy placeholder saves time because it's only added once and applied across your site, instead of having to add a margin to every page's first element. More importantly, if you need to implement an ad below the Top Bar element, you would have to edit every page to remove the margin, and then add the margin to the ad placeholder instead — an issue that's avoided entirely with this method.

You can see this feature live on Mother.ly and Popdust . If you have any questions about implementing this for your site, email support@rebelmouse.com or contact your account manager today.

What Is RebelMouse?
Request a Proposal

Where
Websites Are Built

The Fastest Sites in the World Run on RebelMouse

Let’s Chat

new!

RebelMouse Performance Monitoring

Real-Time Core Web Vitals

Get Started
DISCOVER MORE

Our Core Features

Our platform is a complete digital publishing toolbox that's built for modern-day content creators, and includes game-changing features such as our:

Why RebelMouse?

Unprecedented Scale

RebelMouse sites reach more than 120M people a month, with an always-modern solution that combines cutting-edge technology with decades of media savvy. And due to our massive scale, 1 in 3 Americans have visited a website powered by RebelMouse.

120M+ Users
550M+ Pageviews
17+ Avg. Minutes per User
6+ Avg. Pages per User

Today's Top Websites Use RebelMouse

Thanks to the tremendous scale of our network, we are able to analyze a wealth of traffic data that informs our strategies and allows us to be a true strategic partner instead of just a vendor.

What Clients Say

We’re here to help you weigh and understand every tech and strategic decision that affects your digital presence. Spend less time managing everything yourself, and more time focused on creating the quality content your users deserve.

Case Studies

A Team Built Like No Other

RebelMouse employs a unique, diverse, and decentralized team that consists of 70+ digital traffic experts across more than 25 different countries. We have no central office, and we cover every time zone to ensure that we’re able to deliver amazing results and enterprise-grade support around the clock.

Our team is well-versed in all things product, content, traffic, and revenue, and we strategically deploy ourselves to help with each element across all of our clients. We thrive on solving the complex.

Let's Chat