Search
×
Log in or create an account
If you have an account with us, please log in.

You have no items in your shopping cart.

Frequently Asked Questions

How can we help you?

banner image

Magento 2 'Add to Cart' is not working

The issue is common among merchants who have implemented custom solutions or just migrated to Magento 2 version. There are many variants of the problem outcome, though let’s consider the commonest.

To increase the cart conversion rate, speed up the work of the cart page with AJAX technology. Your customers will see products in the AJAX cart popup where they can edit or refill the shopping baskets without page reloading.

Magento 2 Add to Cart is not working from homepage

The issue: 

  • You have configured a custom theme for your Magento 2 shop. However, you haven’t made any significant changes, just removed some links and added custom CSS. 
  • When adding a product right from the home page you click the Magento ‘Add to Cart’ button and see nothing in the cart, just a refreshed page. Though you receive Magento message that the product has been added to the cart. 
  • Then you go to the product page and add another item to the cart. The cart is updated right after the button is pressed and you see two products there: the one you added right now and the item you placed to cart from the homepage.

The solution:

The solution is simple, there is every likelihood the problem resides in cache. So, enable all caching options built-in your Magento 2.

Magento 2 Add to Cart is not working on product pages: I can’t add products to the cart

The issue:

When adding products from the catalog or product page you are redirected to the checkout page with an empty cart.

The solution:

The thing is that despite the first version, Magento 2 stores root URL in the third path, e.g.: design/head/includes. Usually, the issue occurs after domain change.

  • You need to run an additional SQL query:
UPDATE core_config_data
SET value = REPLACE(value, '<old root URL or domain>', '<new root URL or domain>')
WHERE path = 'design/head/includes';

 

  • Then delete the cache using the command:
rm -rf var/cache/*
Rate the answer?

Total rating: 2.6

If you didn’t find the answer on your question, please, ask here:

Back to top