You can use CDN to store static contents such as images, audios, and files. Speed of fetching from CDN is much faster than access these contents locally. Azure CDN could help to improve performance of your WordPress site running on Azure cloud. In this blog, we will cover how to integrate Azure CDN in WP Super Cache and W3 Total Cache.
1. Create CDN profile: From NEW, search for CDN
2. Create CDN Endpoint: From the CDN profile, click “+Endpoint” to add an endpoint, choose the web site for Origin hostname, e.g.
3. If you have WP Super Cache plugin installed on your WordPress site, you can use WP Super Cache to integrate with Azure CDN:
Edit from WP Super Cache “Settings”, select “CDN” tab, put the URL of Azure CDN endpoint in “Off site URL”, save the change.
Check from developer tool, you should see js/css/images loaded from CDN endpoint, for example:
4. If you have “W3 Total Cache” installed on WordPress site, you can integrate Azure CDN with W3 Total Cache (this solution works well for WordPress multisites):
From “W3 Total Cache” Settings, in CDN section, enable CDN, and select “Generic Mirror” under “Origin Pull” from “CDN Type” list, save the change.
From CDN under “Performance”, put Azure CDN endpoint to “Replace site’s hostname with”, click on “Test Mirror”, “Test passed” indicate the CDN endpoint is connected, save the change.
Use developer tool in your browser to validate that CDN is working.
5. Removing CDN – You can disconnect Azure CDN from WordPress easily by removing the link from your plugin when the CDN is not needed. Delete the CDN endpoint from your Azure portal after you disconnect it from WordPress.