Discuss and resolve questions on Liquid, JavaScript, themes, sales channels, and site speed enhancements.
Hello,
We are facing slow "add to cart" action with our store.
We have customized Shopify to integrate our custom book editor and use the "Ajax API" to allow our users to add products to their cards before redirecting them to the basket page.
We found out that it can take up to 15 seconds for an added product to appear in the cart.
To add a product to our customer basket, we use the AJAX API
What we do is the following:
- We call "add to cart" (https://shopify.dev/api/ajax/reference/cart#post-locale-cart-add-js)
- then we check every 5 seconds if the product is in the cart (https://shopify.dev/api/ajax/reference/cart#get-locale-cart-js)
- We redirect to the basket
We noticed that the product can take up to ~15 seconds to appear in the basket.
We think it's a performance issue on the Shopify API side, does anyone experience the same behavior?
We wonder if it's not related to the large number of products we have (1 customized book = 1 unique Shopify product)
Thank you in advance,
Olivier
Hello @oliviermsb,
There might be an issue with the theme code or some other code-related issue because if you are using Ajax API we can add products to the cart within 3-4 secs.
Ask your developer to fix this issue.
Let us know if you need any further help.
All the best,
CedCommerce
In Canada, payment processors, like those that provide payment processing services t...
By Jacqui Mar 14, 2025Unlock the potential of marketing on your business growth with Shopify Academy's late...
By Shopify Mar 12, 2025Learn how to increase conversion rates in every stage of the customer journey by enroll...
By Shopify Mar 5, 2025