Are you happy with your logging solution? Would you help us out by taking a 30-second survey? Click here


Ajaxify Your Shopify Cart

Subscribe to updates I use ajaxify-cart

Statistics on ajaxify-cart

Number of watchers on Github 45
Number of open issues 9
Average time to close an issue about 1 year
Main language Liquid
Open pull requests 0+
Closed pull requests 0+
Last commit about 4 years ago
Repo Created almost 6 years ago
Repo Last Updated over 1 year ago
Size 216 KB
Organization / Authorcarolineschnapp
Page Updated
Do you use ajaxify-cart? Leave a review!
View open issues (9)
View ajaxify-cart activity
View on github
Fresh, new opensource launches 🚀🚀🚀
Trendy new open source projects in your inbox! View examples

Subscribe to our mailing list

Evaluating ajaxify-cart for your project? Score Explanation
Commits Score (?)
Issues & PR Score (?)


Snippet to ajaxify Your Shopify Cart.

(Use this only if your theme does not already use Ajax, of course.)

The following themes have been confirmed to work with the 'ajaxify-cart' solution without any configuration:

  • Minimal
  • New Standard

How to install

Create a new snippet called ajaxify-cart. Paste in it the content of the ajaxify-cart.liquid file.

Then, include the ajaxify-cart snippet in your theme by pasting the code below in your theme.liquid file right above your </body> tag:

{% include 'ajaxify-cart' %}

How to configure (optional)

No configuration is necessary, but if you want or need to change a few things, go into your snippet and, at the bottom of it, change how the Shopify.AjaxifyCart.init() method is called, by passing to it a configuration object.

Things you can change:

  • addToCartBtnLabel

    Final label on add that cart button after the ajax request, so that you can add more. You could change that to 'Added to bag' for example. Default is Add to cart.

  • addedToCartBtnLabel

Label on add to cart button that shows for howLongTillBtnReturnsToNormal milliseconds after item has been added to the cart. Default is Thank you!.

  • addingToCartBtnLabel

Label on add to cart button while item is being added to the cart. Default is Adding....

  • soldOutBtnLabel

Label on add to cart button when all of the item's stock is in the cart. Default is Sold Out.

  • howLongTillBtnReturnsToNormal

Time during which the add to cart button label is addedToCartBtnLabel. Default is 2000. In milliseconds.

  • cartCountSelector

CSS selector for the element on the page that contains the cart count to update after Ajax request.

  • cartTotalSelector

CSS selector for the element on the page that contains the cart total to update after Ajax request.

  • feedbackPosition

Where to position the feedback after the Ajax request. There are 3 possible values:

  • aboveForm for top of add to cart form,
  • belowForm for below the add to cart form, and
  • nextButton for next to add to cart button.

The default is nextButton.

The configuration object can contain any of the above.

Example, if you wish to position the feedback above the add to cart form, and you wish to use 'Added to bag' as button label when the item has been added to the cart, use the following code:

  feedbackPosition: 'aboveForm', 
  addedToCartBtnLabel: 'Added to bag' 
ajaxify-cart open issues Ask a question     (View All Issues)
  • about 3 years Using ajaxify cart on collections page?
  • about 3 years We have a 'drawer' cart which is not being updated with new line items
  • over 3 years Ajaxify Cart is working fine until I enable Currencies
  • over 4 years Adding item to cart adds 2 items
  • over 4 years After clicking on the add to cart , cart is not updating its number .everything is working fine.
ajaxify-cart questions on Stackoverflow (View All Questions)
  • Shopify - Currency Toggle has stopped working on my Ajaxify Cart
ajaxify-cart list of languages used
Other projects in Liquid