If you’re using WooCommerce for your online store, you’ll eventually run into one of many possible speed and performance issues. One of the most common problems with WooCommerce is slow add to cart (and remove from cart).
This is one of the worst problems you could have on your store as it’s not immediately obvious. It also directly hurts the customer experience right at the point at which they’re trying to buy from you!
Click play on the video above for a video walkthrough of this post.
Clicking the add-to-cart button and having to wait can frustrate customers, lead to abandoned carts, and ultimately hurt your sales. You know if yourself, when a site is slow and frustrating it doesn’t take much for you to click away and want to leave.
We’re specialists in WordPress & WooCommerce speed optimization and have optimized nearly 5000 sites since we started. In this post we’ll share the most common causes of a slow add to cart in WooCommerce and how to fix it.
FREE Checklist & How-To Guide: Fix Your Slow WooCommerce Add to Cart
We’ve boiled this guide down to the 14 fixes that actually move add to cart speed, in the order we work through them on client stores. Back up first, then work through the essential fixes: InnoDB, HPOS, bot blocking, object caching and WooCommerce’s new built-in performance settings. Finish with a quick check that your hosting can handle the load.
Every item is rated by impact, so you know where the biggest wins are. There’s also a plain-English explanation of how to check and fix each one, and a link to the part of the video that covers it. It’s a free Google Sheet. Make a copy, tick things off as you go, and watch your progress update.
Get the free checklist →Click here to request a FREE site audit and one of our team will review your site in conjunction with your goals and tell you how we can help.
If you’re looking to DIY, try our FREE WordPress Site Speed Test. It takes just 90 seconds, there’s no optin required and it’ll give you detailed site speed optimization recommendations.
Table of Contents
Common Causes of Slow Add-to-Cart in WooCommerce
Before we jump into the solutions, let’s first understand some of the common causes of a slow WooCommerce site. By identifying the root cause, you’ll be better equipped to implement an effective solution.
When it comes to speed optimization, often people will throw out random solutions or try random things instead of first troubleshooting the problem and diagnosing the poor cause.
Here are some common causes of slow add-to-cart in WooCommerce:
Poor Quality or Cheap Hosting Environment: WooCommerce is a powerful and feature-rich platform, but it requires a good hosting environment to perform at its best. The difference between good hosting and cheap hosting is akin to the price of a nice lunch versus the cost of a cup of coffee. Cheaping out on hosting is false economy and you’ll lose customers and burn time in managing the site waiting for the backend to load.
Database Issues: Your database plays a crucial role in the speed of your WooCommerce store. Using the more modern InnoDB database tables and the new-ish WooCommerce High Performance Order Storage will make a significant difference to the speed of your ecommerce site.
Bloated Code or Plugins: Another common cause of slow add-to-cart times in WooCommerce is bloated code or plugins. This can happen if you have too many unnecessary plugins installed, outdated plugins that are no longer compatible with your version of WooCommerce, or custom code that is not optimized for efficiency.
Server Location: The location of your server can also affect the speed of your add-to-cart process. If your server is located far from your target audience, it can take longer for data to travel back and forth, resulting in slower add-to-cart times.
1. Use InnoDB database tables instead of the older MyISAM
This one’s particularly important if your WooCommerce site has been around for a while. Older sites often use an outdated database storage engine or format called MyISAM.
This format is slower because it essentially only allows one write operation on a database table at a time.

There are several differences between the two but in simple terms, MyISAM tables will lock a database table while it’s being written to. This means that on a busy site these database write operations start to queue and cause delays in processing which manifest as slower loading to the user.
Think of the database table as an Excel spreadsheet where if one person has it open, another person can’t make any edits.
Innodb tables only lock the row in the database table that’s being written to, so there’s little to no database queuing. It’s like using a shared Google Sheet that multiple users can work on at once.
Converting from MyIsam tables to Innodb tables can give you a solid speed boost particularly in the backend and on higher traffic sites.

The newer InnoDB engine allows multiple writes simultaneously, significantly speeding up your WooCommerce and WordPress backend along with anything else that relies on the database like your cart, checkout and My Account area.
For always recommend you use two backups because every backup system ultimately has some sort of gap or blind spot. As the saying goes, two is one and one is none.
We recommend using BlogVault for WooCommerce backups. It’s fast, it’s reliable and we’ve been using them for 10+ years and never had an issue getting data restored.
Converting to InnoDb Tables
You can easily convert your database tables using a plugin like Servebolt Optimizer.
**BEFORE YOU DO THIS, MAKE A BACKUP
The plugin will convert the tables AND create indexes for a few of the tables which will also help speed things up significantly.
If you’re having trouble with this plugin you can also run commands directly on your database in MySQL command line or PHPMyAdmin to convert the tables. The plugin WP Optimize also has the ability to convert the tables.
Removing other database bloat, especially WooCommerce Transients
Also note that your WordPress database can become bloated over time, especially if you have a large site with a lot of content, products, and images.
You should make it a habit to regularly remove unnecessary data like old revisions, spam comments and in particular WooCommerce Transients.
Transients are temporary data stored for user sessions and the data is stored in the wp_options table which in particular can slow down things like cart, checkout and backend speed.
Typically we setup scheduled database optimization and transient cleanup in WPRocket which is our plugin of choice for WooCommerce sites.
2. Enable High-Performance Order Storage (HPOS)

High-Performance Order Storage (HPOS) is a feature designed to optimize how WooCommerce handles order data, enhancing the speed and efficiency of order processing.
Enabling HPOS can significantly improve your store’s performance, especially during peak traffic times and high transaction volumes. Here’s how to leverage HPOS for better WooCommerce performance:
Reduce Database Load: HPOS minimizes the load on your database by optimizing how order data is stored and retrieved. This helps streamline operations related to adding products to the cart, processing payments, and managing order statuses.
Faster Order Processing: By optimizing the storage and retrieval of order data, HPOS speeds up the entire order fulfillment process. This results in quicker add-to-cart actions, faster checkout experiences, and improved overall site responsiveness.
Enable HPOS in WooCommerce: To activate HPOS, navigate to WooCommerce > Settings > Advanced > Features and enable the HPOS option. Ensure compatibility with your existing plugins and theme by testing thoroughly after enabling this feature.
Monitor Performance Gains: After enabling HPOS, monitor your store’s performance metrics, such as page load times and server response times. Measure improvements in order processing speed and overall site performance to validate the impact of HPOS on your WooCommerce store.
By utilizing HPOS, you can optimize your WooCommerce store for faster order processing and smoother customer interactions. This enhancement not only improves user experience but also helps reduce cart abandonment rates and boosts conversion rates, ultimately driving higher sales and customer satisfaction.
There’s detailed documentation about HPOS and how to enable it on the Wordpress site HERE
Make Sure the WooCommerce Database Update Has Actually Run
HPOS and most of WooCommerce’s performance improvements rely on the database being on the same version as the plugin. Every time WooCommerce updates, it also needs to update its database tables, and on a lot of stores that update quietly stalls part way through.
Go to WooCommerce > Status > System Status and compare the WooCommerce version with the WooCommerce database version. If the database version is behind, WooCommerce is running new code against old tables.
Take a backup, then run the update from the “WooCommerce database update required” notice in your dashboard. If it doesn’t finish, look in WooCommerce > Status > Scheduled Actions for failed or pending woocommerce_run_update_callback actions.
3. Turn On WooCommerce’s Built-In Performance Features
Recent WooCommerce releases have added performance features that are switched off on most existing stores. You’ll find them under WooCommerce > Settings > Advanced > Features.
Cache Product Objects
Added in WooCommerce 10.5, this stops WooCommerce loading the same product over and over within a single request. WooCommerce’s own benchmarks show add to cart up to around 13% faster, with similar gains on product pages and when placing an order. It doesn’t need Redis or any other object cache.
It’s switched on by default for new stores from WooCommerce 11.0, so if your store was set up before that you’ll most likely need to turn it on yourself.
REST API Caching
On the same Features screen you can enable REST API caching, then configure it under WooCommerce > Settings > Advanced > REST API Caching. Backend caching needs a persistent object cache like Redis or Memcached, while the cache control headers option works without one.
Be aware it only caches WooCommerce’s product API endpoints, not the cart. It helps headless stores and mobile apps far more than the add to cart button itself.
Both features are still marked experimental. Turn them on in a staging copy first and run a test order before enabling them on your live store. WooCommerce has more detail in their product object caching announcement and REST API caching announcement.
4. Use a CDN (Content Delivery Network)
Using a CDN will provide one of the biggest impacts on your overall site speed and add-to-cart process. With a CDN we offload a large portion of the overall hosting workload from your primary server or web hosting, onto the CDN. This can significantly speed up operations that rely on the hosting to do the work.
In addition, the farther your site visitors are from your server, the longer it takes for data to travel back and forth. One way to reduce this time is by using a Content Delivery Network (CDN).
A CDN works by storing your website’s static files (CSS, JavaScript, images, etc.) on servers around the world. This allows visitors to access those files from a location closer to them, resulting in faster load times.
Cloudflare is our CDN of choice and even the free plan will make a significant difference to your site speed. If you have a high traffic site then the paid plan at $25 month is 100% worth it.
We also typically setup firewall rules in Cloudflare to filter brute force attacks and spammy crawlers and scrapers – click here for a post on how we setup these rules.
5. Stop Bots Adding Products to Your Cart
This is the cause almost nobody checks, and on busy stores it’s often the one doing the most damage.
On your shop and category pages, the add to cart button for a simple product is a normal link pointing at a URL like /?add-to-cart=123. Crawlers follow links, so every SEO crawler, scraper and AI bot that visits your category pages starts working through every add to cart link it finds.
An add to cart request can’t be cached. It has to run PHP, start a WooCommerce session and write to the database. A bot crawling 5,000 products creates 5,000 uncacheable requests and 5,000 junk sessions, as fast as it can. Your server’s PHP workers get tied up by robots that will never buy anything, real customers queue up behind them, and the server starts throwing 502 and 504 errors.
Check Whether It’s Happening to You
Pull a week of your server’s access logs and count the add to cart requests by user agent:
grep "add-to-cart=" access.log | awk -F'"' '{print $6}' | sort | uniq -c | sort -rn | head -20
If the top of that list is full of names containing “bot”, “spider” or “crawler” rather than real browsers, you’ve found your problem.
Block It in robots.txt
Add these rules to your robots.txt file. They tell well-behaved crawlers to stay away from URLs that use up server resources and are never worth indexing:
User-agent: *
Disallow: /*add-to-cart=
Disallow: /*add_to_wishlist=
Disallow: /cart/
Disallow: /checkout/
Disallow: /my-account/
The * wildcard matters. Add to cart links are generated on your shop and category URLs, not just the homepage, so the rule needs to match the parameter anywhere in the URL. You can check Google has picked up the new file in Search Console under Settings > robots.txt.
Block the Rest With Cloudflare Firewall Rules
Robots.txt is a polite request, and the bots doing the most damage are usually the ones ignoring it. That’s where your CDN comes in. In Cloudflare, go to Security > WAF > Custom rules and create a rule with this expression, with the action set to Block:
(http.request.uri.query contains "add-to-cart=" and
(http.user_agent contains "AhrefsBot" or
http.user_agent contains "SemrushBot" or
http.user_agent contains "MJ12bot" or
http.user_agent contains "DotBot" or
http.user_agent contains "BLEXBot" or
http.user_agent contains "DataForSeoBot" or
http.user_agent contains "PetalBot" or
http.user_agent contains "Bytespider"))
Then add a rate limiting rule for requests containing add-to-cart=, set to around 10 requests a minute per IP with the action set to Managed Challenge. That catches bots that aren’t on the list without getting in the way of real shoppers.
Check this first: if AJAX add to cart is switched off in WooCommerce > Settings > Products, real customers use these URLs too, so stick to the named bot list and keep the rate limit generous. Never block Googlebot or Bingbot at the firewall. They already follow your robots.txt rules.
Check your access logs again a week later. The add to cart bot traffic should have dropped right off. We cover our full Cloudflare setup in our post on Cloudflare rules for WordPress.
6. Use a Persistent Object Cache (Redis or Memcached)
Page caching can’t help with add to cart, because the cart and checkout have to be built fresh for every shopper. A persistent object cache is what speeds up those uncached requests. It keeps the results of repeated database queries in memory, so WordPress doesn’t have to go back to the database for them every time.
Redis and Memcached are the two common options, and most good WooCommerce hosts include one of them. The catch is that having an object cache plugin installed isn’t the same as it working. Go to WooCommerce > Status and check an external object cache is shown as active, and that your caching plugin reports it as connected.
If your host doesn’t offer Redis or Memcached at all, that’s a strong sign the hosting isn’t built for WooCommerce, which brings us to the next step.
7. Choose the Right Hosting Provider
After optimizing your site’s code and using a CDN, the next big influencer on site speed is your hosting provider. When choosing a hosting provider for your WooCommerce store, there are a few important factors to consider:
- Performance and Scalability: A reputable hosting provider offers robust infrastructure optimized for WooCommerce, including SSD storage, server-side caching, and scalable resources to handle traffic spikes.
- Support for Latest Technologies: Choose a provider that supports the latest PHP versions and provides easy management tools for server configurations, ensuring compatibility with WooCommerce and its plugins.
- Server Location: If your target audience is located in a specific region, choose a hosting provider with servers in that region for faster content delivery.
- Uptime and Reliability: You want your store to be available 24/7, so make sure to choose a provider with high uptime guarantees and reliable infrastructure.
Is Your Hosting Specced for WooCommerce?
As a rough guide, if you’re paying under US$10 a month you’re on shared hosting, with your store sitting on a server alongside hundreds or thousands of other sites. That’s fine for a brochure site, but it’s a hard ceiling for WooCommerce, because the cart and checkout can’t be page cached and every one of those requests needs real server resources.
Check how many PHP workers your plan includes, whether you hit that limit at busy times, and whether you’re seeing 502 or 504 errors in your error logs. Any of those points to a store that has outgrown its hosting. Our guide to the fastest WooCommerce hosting covers the hosts we recommend.
Check You’re Running PHP 8.1 or Newer
PHP 8 is significantly faster than PHP 7.4 for WooCommerce, and upgrading is usually just a setting in your hosting control panel. You can see your current version under WooCommerce > Status. Update your plugins first, then switch PHP versions and run a test order to make sure checkout still works.
If you’re looking for a reliable hosting provider for your WooCommerce store, here are some reputable options to consider:
Siteground: Known for its robust performance and customer support, Siteground offers managed WordPress hosting with caching solutions and server-level optimizations.
Cloudways: Offers scalable cloud hosting with optimized server configurations, including advanced caching options and support for PHP-FPM to enhance PHP execution speed.
Kinsta: Specializes in high-performance hosting with Google Cloud Platform, offering automatic scaling, built-in CDN, and PHP 8 support for improved speed and security.
WPEngine: Focuses on managed WordPress hosting, providing server-level caching, built-in CDN integration, and automatic PHP updates to ensure optimal performance for WooCommerce.
8. Monitor and Improve Interaction to Next Paint (INP)
Interaction to Next Paint (INP) measures how quickly your WooCommerce site responds to user actions, such as clicking the add-to-cart button. Improving INP is crucial for enhancing user experience and reducing add-to-cart times. Here’s how to monitor and optimize it:
Monitor with Tools: Utilize tools like Google Lighthouse, PageSpeed Insights, or the Vital Signs Tracker to assess your site’s INP performance. These tools provide insights into how quickly your site reacts to user interactions and identify areas for improvement.
Optimize JavaScript and CSS: Efficiently manage and optimize JavaScript and CSS files to minimize render-blocking resources that can delay INP. Use tools like Autoptimize or WPRocket to concatenate, minify, and defer non-critical scripts, ensuring faster load times for interactive elements.
Reduce Page Load Times: Streamline your site’s overall loading speed to improve INP. This includes optimizing images, leveraging browser caching, and utilizing Content Delivery Networks (CDNs) to deliver content closer to users.
Test and Iterate: Regularly test your site’s INP performance and iterate on improvements. Monitor the impact of changes to JavaScript execution, CSS delivery, and server response times on user interactions to achieve faster and more responsive add-to-cart experiences.
Enhancing INP not only improves user satisfaction but also boosts conversion rates by facilitating smoother and quicker interactions on your WooCommerce store. Regularly monitoring and optimizing INP ensures your site remains responsive and competitive in delivering an exceptional shopping experience.
9. Manage WordPress Plugins
As your WooCommerce site grows, so will the amount of WordPress plugins. While plugins add functionality, having too many or outdated ones can wreak havoc on your site’s performance and potentially lead to more serious problems.
Here are some key steps to manage plugins efficiently:
Evaluate Plugin Usage: Regularly review the plugins on your site and remove any that are no longer necessary. This not only declutters your site but also reduces the risk of potential conflicts or security vulnerabilities.
Keep Plugins Updated: Keep all plugins, including paid ones, up to date. Updates often include performance improvements, bug fixes, and compatibility enhancements with the latest WordPress and WooCommerce versions.
Performance Impact: Assess each plugin’s impact on site performance using tools like Query Monitor or P3 (Plugin Performance Profiler). Identify and replace plugins that significantly affect loading times or resource usage. Consider using lightweight alternatives or custom code to achieve the same functionality.
Quality over Quantity: Opt for plugins known for quality code and performance. Choose lightweight alternatives where possible to minimize their impact on site speed.
Managing the plugins on your WooCommerce site may sound basic, but you would be surprised how many site issues stem from poorly managed plugins. Keep your site lean and optimized by regularly monitoring and updating your plugins.
Check for PHP Errors With Query Monitor
Install the free Query Monitor plugin, load a product page, then add a product to your cart. The PHP Errors panel shows warnings and notices that often never make it into your error log. A warning that fires on every request is a performance problem in itself, and converting your database tables or switching on HPOS can expose older plugin bugs, so check this again after those steps.
While you’re in there, look at the number of database queries. Anything over about 150 on a product page, or any single query taking longer than 0.05 seconds, is worth investigating.
10. Optimize JavaScript
Most of the frontend functionality on a WooCommerce site is powered by JavaScript. This includes features like product sliders, dynamic pricing, and add-to-cart actions. However, excessive use of JavaScript can slow down your site’s performance.
To optimize JavaScript on your WooCommerce store, consider the following steps:
Minify JS Files: Minification reduces the size of JS files by removing unnecessary characters and comments. This helps reduce load times for these files, leading to improved site performance.
Combine JS Files: Combining multiple JS files into one can also help improve site speed as it reduces the number of requests made to the server.
Leverage Browser Caching: You can instruct browsers to cache certain JS files so that they don’t have to be downloaded every time a user visits your site. This can significantly improve page load times for returning visitors.
Defer JavaScript Loading: By deferring the loading of non-critical JavaScript files, you can make sure that important content on your site loads first, improving user experience and reducing bounce rates.
What Doesn’t Work
There are plenty of posts around the web with recommendations for speeding up add to cart. Unfortunately, many of them are written by content writers or generated by AI, rather than based on the practical work of actually fixing add to cart problems. A lot of their recommendations either do nothing or make things worse.
Here’s what won’t help.
Changing PHP Memory Limits
Raising the PHP memory limit does nothing for speed. If your PHP workers run out of memory, they fail and throw fatal errors. Giving them more memory doesn’t make them run any faster.
Disabling or Tweaking Cart Fragments
Cart fragments are requests your browser sends to your hosting to keep the mini-cart or cart icon up to date, showing what’s in your cart and the right number of items. They do put some load on your site, but they have no practical, real-world impact on add to cart speed. Disabling cart fragments, or tinkering with them at all, is a waste of time.
Minifying or Combining CSS and JavaScript
This does nothing for add to cart speed. In some cases it makes speed worse, because it can interfere with the browser caching and edge caching of your CSS and JavaScript files.
Compressing Images or Shrinking Pages
Large images and heavy pages can slow down the initial page load, but they have nothing to do with add to cart speed. Compressing images or making pages smaller won’t make your cart any faster.
Chasing Your PageSpeed Score
Google PageSpeed Insights is a useful speed optimization tool, but chasing the score won’t fix a slow add to cart. When a shopper clicks add to cart, their browser sends a request to your server, the server processes it, then sends back confirmation that the product was added.
PageSpeed measures the front end of your site, while almost everything in the add to cart process happens on the back end.
Work Through It With Our Free Checklist
Want to work through all of this step by step? Grab our free WooCommerce add to cart checklist. It lists every fix in the order we do them, rated by impact, so you can tick them off as you go.