- Product Types
- Prices Types
- Adding Products
- One Time Pricing
- Subscription Pricing
- Subscription Trials Setup
- Installment Pricing
- Donation / Pay What You Want
- Inventory Management
- Product Variants
- Variant Images
- Digital Downloads
- Change Product Availability
- Template Customization
- Product Collections
- First-Time Payment Discounts
- Manage Product Access
- Create Product With Free Trials
- Charge Set Up Fee on Trials
- Product List
- Product Pages
- Create Product Page in Elementor
- Custom Buy Links
- Product SEO
- Change Permalinks
- Custom Fields
- Test Mode
- Make Test Payments
- Edit & Customize Form
- Change Form Template
- Delete SureCart Forms
- Custom Checkout Form
- Add New Checkout Form
- Checkout Form With Gutenberg
- Checkout Form in Elementor
- Custom Thank You Page
- Create Donation Form
- Customize Confirmation Popup
- Include Coupons in URLs
- Pre-Fill Checkout Fields
- Change Checkout Texts
- Password Field in Checkout
- Default Country Code
- Add Terms to Checkout
- Conditional Block Checkouts
- Remove Coupon Field
- Hide Quantity Option
- Disable Quantity Editing
- Disable Item Removal
- Country Specific Purchases
- Update Store Details
- Dark Mode
- Orders & Receipts
- Menu & Slide-out Cart
- Manage Slide-out Cart
- Customers Section Overview
- Create Customer
- Delete Customer
- Update Customer Details
- Edit Invoice Details
- Create Shipping Profiles
- Manage Shipping
- Disable Payment Processor
- Manage Store Notifications
- Manage PayPal Branding
- How to transfer a store to a new organization and assign a license.
- How to Download SureCart Purchase Invoice
- Fix View Order Button
- Fix Express Payment Buttons
- How To Stop Sending WooCommerce Notifications via SureCart?
- Fix PayPal Test Connection
- Fix Sign-In Loop
- Fix Order Confirmation Redirect
- Fix Divi Bullet Point Issue
- Fix Customer Dashboard
- Fix JSON Response Error
- Failed Payment Behavior
- Fix Stripe Zip Code Error
- Fix "Product Can’t Be Blank"
- Troubleshooting Guide
- PayPal IPN Warning Emails
- Caching Configuration for SureCart
- Why iDEAL Might Not Appear in Your Checkout
- Compatibility Guide
Caching Configuration for SureCart
Caching plugins can significantly enhance the performance of your WordPress website. However, when using SureCart, certain caching configurations and optimisation’s can interfere with its functionality. This guide outlines the best practices and essential configurations to avoid conflicts between SureCart and caching or performance plugins.
Exclude REST API Requests
SureCart relies on WordPress’s REST API to handle dynamic content such as customer data, product information, and checkout processes. Caching REST API requests can cause outdated information to be served, resulting in issues like incorrect cart data, failed orders, or broken functionality.
Solution: Exclude all REST API requests from being cached. Ensure that your caching plugin does not cache REST API routes (/wp-json/). Most caching plugins allow excluding specific URLs from caching. Some has exclude REST API fields and some could have a direct UI to change this.
Do Not Defer Core WordPress Scripts
Core WordPress scripts such as wp-api-fetch, wp-a11y, and wp-i18n are essential for dynamic functionality and accessibility. These scripts need to load synchronously, and deferring them can break site functionality.
Solution: Ensure core WordPress scripts are not deferred by the caching or performance plugin.
Scripts to Exclude from Defer:
- wp-api-fetch – /wp-includes/js/dist/api-fetch.min.js
- wp-a11y – /wp-includes/js/dist/a11y.min.js
- wp-i18n – /wp-includes/js/dist/i18n.min.js
- wp-url-js – /wp-includes/js/dist/url.min.js
Avoid Script Combining
Combining JavaScript and CSS files was once a popular optimization technique. However, In environments using HTTP/2, combining JavaScript files is unnecessary. HTTP/2 allows for parallel loading of resources, making script combination redundant and potentially harmful to performance or functionality.
Solution: Disable the option to combine JavaScript files within the caching plugin.
Exclude Dynamic SureCart Pages from Caching
Pages like login, registration, checkout and customer dashboards should not be cached, as caching these pages can prevent users from accessing their accounts or logging in. These are dynamic, user-specific pages that require real-time data.
Solution: Ensure login, account, customer dashboard and checkout-related pages are excluded from caching.
Disable Browser Caching
Enabling aggressive browser caching for dynamic eCommerce data, such as checkouts or cart pages, can lead to outdated data being displayed, such as stale carts or order details. This can create serious user experience and transaction issues, as the data cannot be cleared remotely.
Solution: Disable browser caching for dynamic content, especially for checkouts, carts, and customer account pages. If your performance plugin allows fine-tuning browser caching, make sure to exclude these critical SureCart pages from those settings.
Summary
To ensure SureCart operates without caching-related issues:
- Exclude REST API requests from caching.
- Do not defer essential core WordPress scripts.
- Disable JavaScript file combining, especially in an HTTP/2 environment.
- Exclude login, checkout, and customer account pages from caching.
- Disable browser caching for any dynamic content.
- By following these best practices, your caching configuration will not interfere with SureCart’s dynamic features and will provide a smooth experience for your customers.
- Always test your site thoroughly after making changes to caching settings to ensure all functionality works as expected.
We don't respond to the article feedback, we use it to improve our support content.