Streaming live at 10am (PST)

How to create a bar that floats in the top of a section?


Does anybody know how to create a bar that floats in the top in a certain section, like the tour bar in LiveChat?

I’ve tried several things in “advanced position”, but just can’t get the effect.



Hi @AllyC, this is not officially supported yet in Webflow, but if you’re feeling brave you can manually implement this feature using a custom script embed.

We have an example of a 3rd party “affix” plugin in action here:

And the read-only link to the design tool:

Hope that helps!


I see. Thanks for your help!

Hello, Curious if you expand a bit on the process of getting this working. Anything other than grabbing the embed code and giving the element an id of myaffix?

Not sure if this is what you mean but here is a stripped down version of what you might be asking from a microsite we were putting together.

This is affixed to the top of the page and is intended as a “TOP” navigation button

Hi @danro,

I tried to implement the “affix” plugin to my navBar but it doesn’t work. Is there anything else I have to do beside adding the script and assign an ID “myaffix” to the element?

Much like @vumhoang , I couldn’t get this to work. What are we doing wrong?

I got it working now @ma_tias.
Here’s the missing piece that I found out from @thesergie post in another topic:
It said that: “In both situations, you must provide CSS for the positioning and width of your affixed content.” So I checked again and the Button in the example website has a nested class named “affix” with its own css settings:

.button.affix {
position: fixed;
top: 0px;
z-index: 999;

So what you have to do now is set that up for whatever the element you want to stick on top (navBar) and make sure it has the ID “myaffix”. Hope this helps!

1 Like

You sir @vumhoang have truly earned my great many thanks for today!!! :smiley:

I got this working. It is pretty cool. Thanks for the example.

Could you update the example to include affix-bottom too based on a footer or something scrolling into view?

I can’t figure out how to do this within webflow.