NOTE: Cloudflare may not be used to serve static content in this manner without a paid subscription. Please see Cloudflare’s Terms of Service (section 2.8 as of this writing) for details.
Check out our video How to Use CloudFlare as a Static Content CDN with LSCWP for a step-by-step tutorial.
Set Up Static Content
Setting up your subdomain for static content requires you to configure Cloudflare, your web server, and WordPress.
Log into your Cloudflare account and add a new CNAME record. Call it something like
cdn.yourdomain.com and point it to your origin IP. Make sure the cloud icon is orange so that the static files served through the subdomain can keep using Cloudflare.
If you are using LiteSpeed WebAdmin, create a virtual host for the new subdomain.
If you are using a control panel such as cPanel, Plesk, DirectAdmin, or CyberPanel, create a subdomain and point it to the same docroot as the main site.
From the WordPress Dashboard, navigate to LiteSpeed Cache > CDN. You will see a note that instructs you not to use CDN Mapping for QUIC.cloud or Cloudflare API. That warning applies when using Cloudflare as a reverse proxy. It does not apply to this particular situation, so please ignore it.
Set up CDN mapping to use Cloudflare with the new subdomain, like so:
- Set Use CDN Mapping to
- Set CDN URL to
//yourdomain.com/in the Original URLs box.
- Save changes
At this point, you should be able to view your site’s page source and verify that images and other static files are being served from
Set up Dynamic Content
Configure and enable QUIC.cloud as you normally would, using