WooCommerce supports Ajax add to cart on archive pages by default. Go to WooCommerce → Settings → Products and enable “Redirect to the cart page after successful addition” OFF. Then enable “Enable AJAX add to cart buttons on archives” ON. Your theme must support it, so use a WooCommerce-ready theme and avoid disabling WooCommerce scripts. For single product pages, Ajax is not default for variable products. Use a plugin like “WooCommerce Ajax Add To Cart” or a custom script to submit the form via Ajax. Finally, test cart updates, mini cart refresh, and caching exclusions.
WooCommerce supports Ajax add to cart on archive pages by default. Go to WooCommerce → Settings → Products and enable “Redirect to the cart page after successful addition” OFF. Then enable “Enable AJAX add to cart buttons on archives” ON. Your theme must support it, so use a WooCommerce-ready theme and avoid disabling WooCommerce scripts. For single product pages, Ajax is not default for variable products. Use a plugin like “WooCommerce Ajax Add To Cart” or a custom script to submit the form via Ajax. Finally, test cart updates, mini cart refresh, and caching exclusions.
Read less