Introducing Cloudways Community Forum. Start Discussions and Get Instant Help From Cloudways Community. JOIN NOW

How to Use CloudFlare CDN on CloudwaysNovember 27, 2015

 

In this KB

  • Advantages of CloudFlare CDN
  • How to add a website on CloudFlare
  • How to set up CloudFlare nameserver at domain provider
  • How to set up CloudFlare to view visiting users’ IPs
  • How to use CloudFlare with Breeze WordPress Cache

 

Not only does Cloudways provide a blazing-fast hosting stack on its platform, it also allows users to use CloudFlare CDN to reap the extra benefits of cloud hosting.

Advantages of CloudFlare CDN

CloudFlare speeds up websites by 100%, with 65% fewer requests and 60% lesser usage of bandwidth. It works with both static and dynamic content by caching the static resources including CSS, JavaScript, and images. You can also get an SSL certificate from CloudFlare.

It also protects websites from Denial of Services (DoS) attacks and identifies new types of vulnerabilities popping up by the passing minute. The best part is that CloudFlare comes with a Free plan.

Step 1: Create a CloudFlare Account and Add a Website

1. Visit the CloudFlare website and click on the Sign up link at the top of the page.

2. Create a CloudFlare account using your email address and password. Click Create an account now to proceed.

3. Enter the domain for your website and then click Begin Scan. It’s not necessary to add www to the domain. For example, if your website is example.com, the domain will be example.com

CloudFlare Cdn

4. CloudFlare will scan the domain’s DNS records. This will take approximately 60 seconds to complete. Once the DNS scan has finished, click Continue.

CloudFlare Cdn

 

5. A list of all the DNS records found is displayed, including your subdomains. Here you can route CNAME, A records, amongst others through CloudFlare servers by clicking on the gray cloud icon.

CloudFlare Cdn

6. Select a plan according to your needs, the free plan for example, and then click on Process and continue.

CloudFlare Cdn

Step 2: Setup CloudFlare Nameservers at Domain Provider

In this step, you are given the CloudFlare nameservers for your domain. The CloudFlare nameservers are assigned to your domain and listed on this page. You can also find your CloudFlare nameservers in your CloudFlare dashboard under Overview.

CloudFlare Cdn

Finally, update the nameservers for your domain with the CloudFlare nameservers as shown above. Here are the steps required to update your nameservers:

1. Log into CloudFlare account and make note of your nameservers.

nameservers2. Determine your domain registrar (e.g. GoDaddy, NameCheap .. etc.) and login to your registrar account.

3. Update your nameserver records to the CloudFlare nameservers.

4. Confirm your changes through the CloudFlare dashboard.

CloudFlare dashboard

After you have edited the DNS records, click continue and after a while, you will receive an email confirming that your domain is using CloudFlare DNS and is now being optimized.

Step 3: Allow Web Server to See the Visiting User’s Real IP Address (When/If needed)

When using CloudFlare to see the visitors’ real IP address instead of 127.0.0.1 on your website, you will need to Enable CloudFlare option on the Cloudways Platform. First, log into the Cloudways Platform with your credentials. Then click on the Advanced tab in the Server Settings & Packages section under the Server Management area. 

Under the Advanced tab. select CloudFlare under WAF Module and save the settings by clicking on Save Changes.

Server Settings and Packages Cloudflare

If there is still any issue with the real IPs not appearing on the website, then you can contact our Live Chat support for further assistance.

Using CloudFlare with Breeze WordPress Cache

CloudFlare CDN requires no special configuration to work with Breeze WordPress Cache. If you have enabled CloudFlare minification, we suggest that you disable minification in Breeze.

Have Questions? Ask From Our Helpful Community

One Response

  1. Savvas says:

    Hi, this is a great tutorial. I would like to see some tutorial on how we can configure cloudflare’s settings (free/pro plan) for optimal performance. This is really hard to find!
    Thanks

Still need help? Our support team is waiting to help you. Ask them now