Sticky Add to Cart on Shopify Mobile, Done Properly
On a phone, the Add to cart button on a product page scrolls out of view almost as soon as the shopper starts reading. By the time they have looked at the photos, read the description and checked the reviews, the button is several screens up. A sticky add to cart bar brings it back. Done well, it is one of the simplest mobile improvements you can make. Done badly, it covers content, shifts the layout and annoys people. This guide covers both.
Facts in this article come from the source code of Shopify's Horizon theme, Google's Cumulative Layout Shift guidance on web.dev, and the W3C's WCAG 2.2 Focus Not Obscured criterion, all checked on 19 November 2026.
What is a sticky add to cart bar?
It is a slim bar fixed to the bottom of the screen on product pages, usually showing a small product image, the name, the selected variant, the price and an Add to cart button. It appears once the shopper has scrolled past the main buy button, so the action is always one tap away without scrolling back up.
Shopify's own Horizon theme ships with one. In Horizon's product information section there is a setting to enable the sticky add to cart, and it is switched on by default. If you are on Dawn or an older theme, it needs either a theme setting from your theme developer, an app, or custom code.
When does a sticky add to cart bar help?
It helps most when the product page is long and the decision happens below the buy button. That is common on Indian D2C stores, where shoppers scroll for reviews, delivery dates, COD availability, ingredients or size guides before deciding.
It tends to help when:
- Your product pages are long, with reviews, FAQs and rich content below the fold.
- Most of your traffic is mobile, which is the case for most Indian D2C stores.
- Products are simple to buy, with one or two variant choices.
- You sell repeat or low-consideration products where the shopper already knows what they want.
It helps less when the page is short and the main button is never far away, or when the product needs several choices (size, colour, personalisation) that do not fit in a bar. In that case the bar should scroll the shopper back to the options rather than add an unconfigured product.

Photo: NeONBRAND via Wikimedia Commons, CC0
When should the sticky bar appear and disappear?
Horizon's code is a good reference because it is Shopify's own implementation. It uses the browser's IntersectionObserver to watch the main buy buttons and the footer, and it behaves like this:
- The bar stays hidden while the main buy buttons are on screen.
- It appears only once the main buttons have scrolled above the top of the screen, not when the shopper has not reached them yet.
- It hides again when the main buttons come back into view.
- It hides when the footer approaches, so it does not cover footer links.
- It stays hidden while a chat window is active, so it does not fight the chat widget for the same space.

That last point matters on Indian stores, where WhatsApp chat buttons and support widgets often sit in the bottom corner. A sticky bar and a floating chat button competing for the same space is a common mobile layout problem. Decide which one owns the bottom of the screen on product pages, and move the other.
How do you avoid layout shift with a sticky bar?
Layout shift is when visible content jumps while the page is in use. Google measures it as Cumulative Layout Shift, and web.dev says a good score is 0.1 or less, with anything above 0.25 counted as poor. A badly built sticky bar can push content around every time it appears.
The rules that keep it clean:
- Position it as fixed, over the page. The bar should sit on top of the content, not be inserted into the page flow where it pushes things down.
-
Animate with transform, not position. web.dev recommends using
transform: translate()to move elements rather than changing top, bottom, left or right, because transforms do not trigger layout shifts. - Reserve space at the bottom of the page. Add bottom padding equal to the bar's height, so the last content on the page is not hidden behind it.
- Respect reduced motion. If the shopper's phone is set to reduce motion, show and hide the bar without the slide.

If your product page already feels slow when tapping buttons, a sticky bar with heavy scripts will make it worse. Our guide to fixing slow interactions on Shopify covers how to check that.
What accessibility problems do sticky bars cause?
The main one is covering what has keyboard focus. WCAG 2.2 success criterion 2.4.11, Focus Not Obscured (Minimum), says that when an element receives keyboard focus, it must not be entirely hidden by author-created content. The W3C's own explanation names sticky footers as a typical cause. A shopper using a keyboard or switch device who tabs to a link near the bottom of the screen can lose it behind your bar.
Practical fixes:
- Add
scroll-padding-bottomto the page equal to the bar height, so focused elements scroll into view above it. - Give the bar a clear accessible label. Horizon labels its bar as the sticky add to cart region.
- Make the button at least 24 by 24 CSS pixels, the WCAG 2.2 AA minimum, and in practice closer to 44 pixels high for thumbs.
- Keep the price and variant in the bar in sync with the main form. A bar that says "M" while the main form says "L" is worse than no bar.
Our article on accessibility on Shopify stores covers the wider checklist.
Screen readers need care too. The sticky bar usually repeats the product name, price and button that already exist higher on the page. If both are announced in full, a screen reader user hears everything twice. Give the sticky bar a clear label, such as "Quick add bar", keep its button text identical to the main one, and make sure it does not trap focus. Test it once with TalkBack on Android, since that is what most Indian shoppers using a screen reader will have.
Finally, check the bar on the smallest phone you support. A product title, a variant name, a price with a struck-through MRP and a button rarely fit in one row on a narrow screen. Decide in advance what gets dropped first. Usually the title goes, because the shopper already knows which product they are on, and the price and button stay. If the product has variants, the selected size or colour should stay visible too, so nobody adds the wrong one by mistake.
Should the sticky bar add to cart directly or scroll up?
It depends on the product:
- Single variant products: add directly, and show clear feedback such as a cart drawer opening or a short "Added" state.
- Products with one choice already made: add directly with the selected variant shown in the bar, so the shopper can see what they are adding.
- Products needing choices: if no size has been selected, the bar button should scroll to the options or open a small option picker, never add a default size silently.
- Sold-out variants: the bar should say sold out, or offer back-in-stock alerts, matching the main button.
How do you test whether the sticky bar works?
Test it on real phones first: a small Android, a large Android and an iPhone, with the browser toolbar shown and hidden. Check that it never covers the WhatsApp button, cookie banner or chat, and that the last line of the page is readable.
Then measure. Compare add to cart rate on mobile product pages before and after, ideally with a proper A/B test rather than a before-and-after comparison that mixes in sale periods. Avoid launching it the week of Black Friday on 27 November, when traffic patterns change too much to read the result. For mobile checkout itself, our guide to mobile checkout optimisation picks up where this leaves off.
A sticky button helps only when the rest of the product page works. Our post on what a Shopify CRO audit usually finds covers the wider mobile checks.
Want a sticky add to cart that does not break your page? Email hello@exactwhy.com with the subject "Sticky add to cart" and a link to one product page. We will check your current mobile product page, how it behaves with your chat and banners, and whether a sticky bar is likely to help, free. If you want us to build or fix one, we quote after the review, and ongoing CRO support is available on a monthly retainer. You can also reach us through our contact page. We reply within 4 hours.