What you need to know about caching and WordPress!

7 min read

One of the most frequently asked questions and topics we deal with at WP EasyCart is caching and caching related issues when it comes to eCommerce.  Hopefully this guide can help explain this complex and confusing topic as it relates not only to your WordPress in general, but also eCommerce.

What is Caching?

Caching is a way to speed up a website delivery by preparing, compressing, and having a stored copy of the content the customer is requesting. In many cases, this is a good thing, but sometimes in a dynamic shopping cart situation, we do not always want caching.

Caching can come from various sources:

  • Web Hosts can implement server side caching which you may or may not be able to control. Your website may be fast, but with eCommerce, the data may get messed up.
  • WordPress Plugins often are installed, sometimes multiple plugins, that will minify, cache, and try to boost performance but ultimately cause trouble in WordPress eCommerce.
  • WordPress Themes have started to use caching and implement their own speed boosting techniques, but can again lead to caching and data trouble in dynamic sites.

Caching can also come in various methods:

  • File caching is simply storing and feeding users pages and file contents to quickly speed the site up.
  • Object caching is a way to store and feed database retrievals so that the data is given to users quickly in an effort to speed the site up.
  • File minification, while not really caching, is often used by caching plugins in an effort to compress Javascript or CSS files to make them smaller.
  • Cookie caching will store these unique identifiers in an effort to retrieve less data and speed up your site.  Often these unique identifiers are important for ecommerce sessions.

Common issues that can arise from Caching on a website with ecommerce

There are many common signs that you have caching issues.

  • Users add items to their shopping cart and are not able to delete or update their cart items.
  • Users add items to their shopping cart and see randomly other items in their shopping cart.
  • Users begin checking out and see other user data… this is an obvious sign as caching of database calls and cookies is present.
  • Users checkout but cross data with another user account.
  • Changes are made to a product such as titles, descriptions, prices but when you view the front end, it is old data… only thing it can be is caching.

Is Caching a security risk?

Yes, we like to think so… because you are the owner and WordPress developer on your website, and you alone control all the coding, plugins, themes, and mixed data on your site, it is critical you understand what each and every plugin, theme, and piece of data is doing. While we can control our plugin, the WordPress platform is a very fluid area and every plugin and change injects coding from sources all around the world, therefore they can all behave differently in mixed environments. What plugin A does may have an effect on what plugin B and plugin C do. What Theme A does, will affect what plugin B and plugin C experience.

For this reason, we can only recommend that known and trusted plugins with reputable support and followers be installed in WordPress. We like to minimize plugins, thereby minimizing coding conflicts.

How to Solve Caching Issues

This is what everyone wants to know… you identify that you have a caching issue, now how do you solve it in real world situations. Plugin developers blame hosting and other plugins, hosting companies blame plugin developers, everyone blames everyone else about the issue, but solving the problem can be a confusing process to most users and in the end it’s impossible for any theme, plugin, or wordpress developer to have 100% conflict free systems.   Everyone has a unique blend of these compnents on their WordPress, so it’s up to the site owner to make sure they can troubleshoot and navigate these issues.

Here is what we typically do related to WP EasyCart:

  1. First off, we go to WP EasyCart -> Settings -> Checkout and make sure “Prevent Cart Caching” option is turned ON. This will load the cart and account using best techniques as best we can. Remember, it still depends on every other plugin and theme coder to have a happy system, so while this tries it’s best to load correctly, it can be overwritten by others. If problem still persists, move to step 2.
  2. Next easiest step, look in your plugins and deactivate all caching plugins. In fact, deactivate all plugins except EasyCart, see if the problem resolves itself. If so, enable each one at a time until you find out what plugin is causing the caching behavior you see. If this doesn’t work, move to step 3.
  3. If no plugins cause the caching issue, then look at your theme, switch to a simple twenty-twenty stock WordPress theme. Does the caching behavior exist or not, if so, contact the theme developer and see if they have ways to disable caching. If this doesn’t work, move to step 4.
  4. Contact your web host provider. Server side caching is not something you would recognize right away. It works great on static sites, but eCommerce programs by any company will struggle with server side caching. Ask your web host to turn off all caching systems. If that is not possible, and some may not do that, then ask them to add exclusions to the store, cart, and account pages in your WordPress. If the problem persists, it may be time to find a more non-cache friendly host.
  5. Ask your web host provider to also exclude the WP EasyCart cookie  ‘ec_cart_id’ which can also be useful in keeping users sessions accurate and alive.  This unique cookie is useful across the entire account and checkout process.

In the end, caching can be hard to replicate. Some days it may seem to store old data, then it may work fine. The key is that you cover your basis with the 4 tips above and eliminate the most obvious caching mistakes. Worst case scenario, you need to move to a more non-caching host provider.

Web Hosting Specific Issues

To date, WP EasyCart has been working great across all these platforms, but some require a few tweaks to make eCommerce run smoothly.  Here are a few hosts and their unique aspects we have come across over the years.

Godaddy Hosting – while good hosting, we have a very mixed review of customers who sometimes get good servers and caching is very limited problem, while others get on a host that caching is severe and causes ecommerce issues.  Some tech support users have been reported as helpful and add exclusions, while others do not.

Siteground Hosting – This is also good hosting, but they do have very heavy caching on the server side and optimizers that can cause issues with any eCommerce platform.  Try deactivating any optimizers and see if the Siteground staff will add exclusions to the above #4 and #5 steps.

WP Engine – Great hosting, fast and very reliable, but you should contact them and have exclusions applied to the #4 and #5 above.  They have been good with technical support requests and chats on this topic and accommodate it well.

Bluehost, Hostgator – Generally these are more traditional non-proprietary hosting platforms with good success right out of the box.  They run standard cPanels which  give you basic control over your web hosting and we have not ran into many caching issues at all on these platforms.

Are there ways to Cache successfully?

Yes, we have had good luck with caching and eCommerce. Here are a few things we like to follow and use.

  • We like to stay away from SiteGround or GoDaddy just because they do tend to cache heavily. If starting with a fresh hosting platform, might jump toward BlueHost or WP Engine which are a couple of our favorites. We have many users on all these platforms, it’s just a recommendation if starting fresh.
  • Many hosts like WP Engine will gladly add exceptions to any caching server side, just chat with them and ask they exclude the store, cart, and account as well as our cookie ec_cart_id. They are starting to do this automatically nowadays.
  • Make sure you only use one caching plugin. We have seen sites with 6 caching plugins running… don’t be that guy.
    • WP Super Cache works great with just default settings.
    • WP Rocket is blazing fast, again, just use default settings, don’t go crazy with custom settings without knowing exactly how they affect all code from all plugins.

If you are developing a WordPress, caching can be very frustrating as you make changes and do not see them instantly… this means it’s caching somewhere. EasyCart changes should be instant, so if not, you know you have a caching issue.

Are there Caching solutions to avoid?

Yes, we have found server side caching is good for static websites, but a dynamic shopping system it can cause issues with. Try to avoid using CloudFlare or other server/hosting based solutions to cache.

Firewall and security software can also cause issues. We have noticed GoDaddy is notorious for having caching systems running on their servers and often refuse to turn them off. GoDaddy also offers firewall caching which is hard to detect but can be disabled. You may have to hunt for it on this hosting platform or search through your products and settings in order to disable it.

WP Compress Payment Issues

If you are using WP Compress you may run into issues. Most payment providers require their javascript files to load directly from their website. This can cause errors on checkout for those payment providers if you choose to offload to a CDN. WP Compress has an option that is absolutely going to break this. To fix it, turn OFF the setting External URLs, again OFF. Here is their doc on turning it on: https://help.wpcompress.com/en-us/article/using-external-urls-s3-spaces-etc-14ezbh3/

Updated on March 14, 2025