BunnyCDN full page caching for WordPress: complete setup guide
Full HTML caching with BunnyCDN turns your WordPress site into a static-speed machine. Your pages are served directly from BunnyCDN's global edge network, bypassing your origin server on every cached request. The result: dramatically faster load times, lower server load, and a CDN that handles traffic spikes without touching your server.
This guide covers the complete setup: DNS zone, pull zone, SSL, LiteSpeed Cache integration, and the 7 edge rules that make full-page caching work correctly without breaking logins, admin access, or dynamic content.
- A BunnyCDN account — free to create at bunny.net
- Access to your domain registrar (to update nameservers)
- LiteSpeed Cache plugin installed and active on your WordPress site
- Your origin server's IP address
Step 1: Set up BunnyCDN DNS
BunnyCDN DNS is a fast anycast DNS network. Using it alongside your pull zone gives you both CDN and DNS performance in one dashboard. This step creates a DNS zone for your domain and updates your registrar to point to BunnyCDN's nameservers.
Creating a DNS zone in the BunnyCDN dashboard
BunnyCDN assigns two nameservers — update these at your registrar
DNS zone with A record and CNAME records configured
Step 2: Create a pull zone
A pull zone is what BunnyCDN uses to fetch and cache your content. You create it once, point it at your origin server, and BunnyCDN handles delivery from edge nodes worldwide.
Creating a new pull zone — set origin type to Origin URL
Pull zone created — note the .b-cdn.net hostname for your CNAME record
Pull zone management — add your custom hostname here
Step 3: Add SSL certificates
BunnyCDN can auto-generate a free SSL certificate for your custom hostname, or you can upload your own.
SSL settings in the pull zone — generate the free certificate and enable Force SSL
Step 4: Configure LiteSpeed Cache for BunnyCDN
LiteSpeed Cache has native BunnyCDN integration. Connecting the two means LiteSpeed can purge CDN cache automatically when you publish or update content.
Step 5: Fine-tune caching settings
Before adding edge rules, get the basic caching configuration right in BunnyCDN's pull zone settings.
- Browser Cache TTL: Set to 30 days (2592000 seconds) for static assets. Browsers cache these locally and avoid re-requesting them on return visits.
- Origin Cache TTL: Set to 1 day (86400 seconds) for HTML pages. This is overridden per-path by your edge rules.
- Vary Cache: Enable Vary Cache by Cookie if your site serves different content to logged-in users. This prevents cached logged-in pages being served to guests.
- Ignore Query Strings: Disable this — WordPress uses query strings for cache-busting (e.g., ?ver=6.4). Ignoring them would serve stale CSS and JS.
- Enable Gzip/Brotli: Enable both. BunnyCDN compresses responses at the edge before delivery, reducing transfer size 60-80% for text content.
Pull zone caching settings — TTL, Vary Cache, and compression options
Step 6: The 7 edge rules for full-page caching
Edge rules are where full-page HTML caching is actually configured. These 7 rules work together: rules 1 and 2 enforce canonical URLs, rule 3 bypasses cache for sensitive paths, rules 4 and 5 set long TTLs on static assets, and rules 6 and 7 control browser-side caching. Apply them in this order.
Edge rules panel in BunnyCDN — add each rule in order
Configuring conditions and actions for an individual edge rule
Ensures every page is served with a consistent canonical URL, preventing duplicate content issues at the CDN level.
Condition: Hostname does not match www.example.com
Action: Redirect URL to https://www.example.com{Path}{QueryString} with 301 status
Redirects non-www traffic to www at the edge, before it reaches your origin server. Consistent with Rule 1 but catches additional URL variations.
Condition: Request URL matches ^http://example.com/ (regex)
Action: Redirect URL to https://www.example.com{Path}{QueryString} with 301 status
Bypasses CDN cache for WordPress admin, login, checkout, cart, and any paths that must never serve cached responses. This is the most important rule — get it wrong and logged-in admin sessions serve cached pages.
Condition: Any of the following URL paths match:
Action: Override Cache Time = 0 (do not cache)
Sets a long server-side cache TTL for CSS and JavaScript files. These change infrequently and should be cached aggressively at the edge.
Condition: Extension matches css OR js
Action: Override Cache Time = 2592000 (30 days in seconds)
Sets an even longer server-side cache TTL for media files. Images and fonts rarely change and benefit from extended edge caching.
Condition: Extension matches jpg OR jpeg OR png OR gif OR webp OR svg OR woff OR woff2 OR mp4
Action: Override Cache Time = 31536000 (1 year in seconds)
Sets Cache-Control headers that instruct browsers to cache CSS and JS locally. Visitors who return to your site skip re-downloading these files on every page load.
Condition: Extension matches css OR js
Action: Set Response Header = Cache-Control: public, max-age=2592000, immutable
Applies consistent browser caching headers to all static asset types, ensuring images, fonts, and media files are cached by the browser across sessions.
Condition: Extension matches jpg OR jpeg OR png OR gif OR webp OR svg OR woff OR woff2
Action: Set Response Header = Cache-Control: public, max-age=31536000, immutable
Step 7: Verify the setup
Once all rules are saved, test the cache before calling it done.
Test with curl
The fastest way to confirm BunnyCDN is serving cached responses is to check the response headers. Look for x-bunny-cache: HIT on repeated requests:
On the first request you'll see x-bunny-cache: MISS (fetching from origin). On the second request to the same URL you should see x-bunny-cache: HIT (served from edge). If you're still seeing MISS after multiple requests, check Rule 3 isn't over-matching your paths.
Test with your browser
Open DevTools (F12), go to the Network tab, and reload your homepage. Check the response headers on the HTML document request. Look for the x-bunny-cache header and confirm the CDN URL is serving your assets (images, CSS, JS should show your CDN hostname in the initiator).
Test admin access
Log into WordPress admin and confirm the dashboard loads correctly. If Rule 3 is configured properly, /wp-admin/* should bypass cache entirely and you should see a fresh, functional admin interface. If you see a stale page or get logged out, revisit Rule 3's path matching.
Test a logged-in page view
Log in as a regular user and browse the front end. The toolbar should appear. If a cached page is served to a logged-in user without the toolbar, your Vary Cache by Cookie setting is not active or your login cookie name is not correctly configured.
Running this on a RemarkableCloud managed VPS means LiteSpeed is pre-configured and BunnyCDN cache purges on publish automatically. The server side handles itself.
See what's included →A fast WordPress site starts with a fast, managed server
RemarkableCloud's managed VPS includes LiteSpeed, proactive monitoring, daily backups, and a free mail gateway on every plan. BunnyCDN handles the edge; we handle everything underneath. From $2 your first month.
See managed VPS plans


