Not all of my WordPress static URLs are being served by BunnyCDN

In some cases, you will notice that even after configuring the BunnyCDN plugin in WordPress, some or even all of the URLs for the static resources are not coming from BunnyCDN. In this guide, we will look into the most common reasons why this happens and how to solve them.

 

HTTP/2 Push

Your server might be configured to automatically push the resources to the browser, even without the browser requesting those. In this case, you will need to configure your server to disable HTTP/2 Push for requests that are already served from the CDN.

Page Caching

If your WordPress is configured with a static page caching plugin, it might be holding an older version of the pages in cache, before the CDN plugin has been activated. After activating the plugin for the first time, we suggest purging the cache of any caching plugins just in case to ensure that the new URLs are set.

This can also apply to various static caching configured by the web hosting itself. If you are aware your web hosting is actively caching pages, make sure to purge that as well.

Incorrect URL Detection

Our plugin works by detecting the URL of your WordPress page based on the settings inside of WordPress itself. In case no URLs are getting detected, we suggest checking that the URL in the Advanced Settings of the plugin matches with the actual URL of your website where the files are served from.

CSS/JavaScript Files

Some of the static resources are loaded out of CSS files or dynamically by JavaScript. BunnyCDN cannot modify those files to replace the URLs. In these cases, we suggest checking the CSS files or JavaScript scripts for any direct URLs that point away from the CDN.

Dynamically Generated Scripts or Lazy Loading

On some occasions, we noticed that some WordPress plugins might load images dynamically from a script that is generated on the fly. In those cases, our plugin cannot access the URLs as they are usually encoded within JavaScript. If this is the case, we suggest checking with the plugins themselves if they offer configuration for the CDN or directly specifying which URLs to load in order to force them to use the CDN version.

Table of Contents

Was this article helpful?
7 out of 20 found this helpful