Position sticky not working on mobile breakpoint

I set a tab to position sticky (0 top margin) on all breakpoints and it was working perfectly as expected. However, when I later changed the position on mobile to static it works as expected (Desktop and tablet sticky, mobile static). Now I change the static position on mobile to sticky, it’s not working, it’s behaving as if static. (Desktop and tablet sticky still works). Help me out please.

Hi Aliyu Sabo,

Does the container in which you have your sticky element on mobile still have another element in that container?

A sticky element can only by sticky if it’s not the only element in it’s container. I think that because of making it responsing another element is in the container has a display: none; which causes that the sticky element is that only element in the container.

Kind regards,
Edwin Emmen