- Go to Admin -> Content ->Configuration
- Choose your store or store view -> edit
- Open HTML Head section and add the below code to the Script and Style Sheet box:
You can make changes to the style as you need
4. Now to to Footer and open the Miscellaneous HTML box. Add the below code :
That’s it. Now clear the cache and reload the frontend and you should see the sticky header.
Tested on Magento 2 upto Magento 2.3.4 and it works.
If you face any issues, let me know using the comment box