Using Cloudflare with WordPress
Step #1 – Preparing the Server
Here are some tweaks that you can do if you have control of your web hosting environment. Such tweaks will make your life a little easier.
If you do not have control of your web server, you can feel free to skip this section.
It is a good idea to install the latest and stable version of Mod_Cloudflare on the Apache server which will ensure that your Cloudflare will work transparently by making sure your IP is logged correctly in both Apache logs and web applications. In addition, Mod_Cloudflare will now also make sure that Flexible SSL will work transparently.
Step #2 – Install the WordPress Plugin
For you to be able to install the plugin, you will need to login to your WordPress dashboard and go to the ‘plugins’ section. Search for ‘Cloudflare’ and select the ‘WordPress’ plugin.
Once you have installed the plugin, click the ‘Activate Plugin’ button; after this, you may configure the plugin by going to ‘Settings’ and clicking the ‘CloudFlare’ menu option.
You will be greeted by the login page once you enter in your credentials.
To find your API key, look in the drop down in the top right corner of your ‘Cloudflare’ dashboard and click ‘My Settings’. The API key should be there under the ‘Account > API Key’ section.
You will find the Global API Key Panel on that page.
After you have typed in your ‘Global API’ key into the WordPress dashboard, click on ‘Save API Credentials’ and you will be ready to go.
Step #3 – Load Optimized Defaults
Now you can enable the Optimized Defaults in the WordPress plugin so that Cloudflare will work optimally on your platform. You may do this by clicking on the ‘Apply’ button next to the setting.
‘Automatic Cache Purge’ should allow you to automatically flush the Cloudflare Cache when your WordPress site appearance is updated, you can enable this too.
Step #4 – Conclusion
After you have completed all these steps, you can now improve your security and performance by customizing your Cloudflare configuration.