Skip to main content
Easy Digital Downloads Documentation
Documentation, Reference Materials, and Tutorials for Easy Digital Downloads

Configuring Cache for Easy Digital Downloads

WP Fastest Cache

In order to use WP Fastest Cache with Easy Digital Downloads, there are a quite a few settings to change. This is a basic list of the settings that need to be configured.

Settings

Logged-in Users: Enabled. This
Preload: Disabled
New Post: Enabled
Updated Post: Enabled
Combine Js: Disabled. This setting frequently causes the JavaScript from EDD to be malformed when updates are made, sometimes causing checkout and adding to cart to fail.

If you are using the Free Downloads Extension, please enable the ‘Mobile’ checkbox, as this will prevent your mobile users from being shown the desktop version of the free downloads form.

Exclude

Add rules to the Exclude section for:

Exclude Pages:

Your checkout page. By default this is `checkout`

Purchase Confirmation page. By default these URLs contain the `purchase-confirmation` slug.

Note: If you have renamed the default checkout, purchase confirmation, or purchase history pages, you’ll need to use their page URLs here instead of the defaults.

Exclude Cookies:

In order for EDD’s cart to work you’ll need to exclude the `edd_items_in_cart` cookie.

To make sure that cart errors are not cached, exclude this cookie `edd_cart_messages`

Once a purchase is complete, make sure the purchase confirmation isn’t cached by excluding the `edd_purchase` cookie.

If your site uses fees in anyway, exclude the `edd_cart_fees` cookie.

In order to support cart recovery, exclude the `edd_resume_payment` cookie.

Make sure the cart itself isn’t cached by excluding the `edd_cart` cookie.

If you are using discounts, be sure to exclude the `cart_discounts` and `preset_discount` cookies.

A complete list can be found below:

edd_items_in_cart
edd_cart_messages
edd_purchase
edd_cart_fees
edd_resume_payment
edd_cart
cart_discounts
preset_discount
edd_cart_token
edd_saved_cart

Exclude JS:

To make sure that the JavaScript file for EDD’s Checkout is always the most up to date, you’ll want to exclude it from the cache. Not excluding could prevent your site from allowing customers to checkout when EDD is updated.

If you continue to have issues with WP Fastest Cache with these settings, please reach out to the WP Fastest Cache support team directly at https://www.wpfastestcache.com/contact-us/

WP Engine

If you are hosting your website with WP Engine you can add Custom Cache Exclusions using your administration panel.

WP Engine provides a documentation article https://wpengine.com/support/cache/#Custom_Cache_Exclusions on how to exclude items from cache.

In some cases when passing the “discount” parameter in the URL the discount code is not being added to the Checkout page once the customer reaches it. For that to work you need to add the “discount” argument as an exclusion following the steps listed in the article above.

It would need to be added in the format: arg: discount=

Following the same example you can add other arguments from being excluded from their caching.

Kinsta

For users hosting with Kinsta, it is possible that the Checkout page session data to be cached. The way to fix it is from your hosting account Tools panel by enabling “Remove Set-Cookie headers”.