Cloudflare is a content delivery network (CDN). A CDN is a distributed network of servers that provides several advantages for a web site.
Table of Contents
Use Cloudflare to maintain speed and security in our website
Cloudflare is essential for our websites because it gives high performance in loading the site, and the most critical point is that it protects our sites from the different attack such as (DDoS) attacks which can keep our site down for more than a days and this can give the bad impression to the visitors and can stop our daily transactions. Cloudflare helps to improve security by blocking threats before they even reach a site. Cloudflare’s CDN can also provide some protection against Distributed Denial of Service (DDoS) attacks.
Set Cloudflare for Maximum Speed and Protection.
After you log in to the Cloudflare set up all the domain nameservers and do all the setup you should in the beginning what the Cloudflare system responds.
1. Choose a speed on the menu bar
2. Enable AutoMinify on javascript,CSS,HTML

After clicking on the speed button and make sure to enable Javascript, CSS, HTML present on the right side.
It shortened your code removing unnecessary characters in the source code, which helps to load your website faster
Enable Brotli
Brotli is a generic-purpose lossless compression algorithm that compresses data using a combination of a modern variant of the LZ77 algorithm, Huffman coding, and 2nd order context modeling, with a compression ratio comparable to the best currently available general-purpose compression methods.

Enable Mobile Accelerated Links

Enable Rocket Loader™
It helps to improve the paint time for pages which include JavaScript.

Click on Caching from the menu bar

Caching Level

Browser Cache Expiration

Click on the Page rule from the Menu bar

- Go to Page rule.
- Click on Create Page Rule.
- Copy the URL of your website and put /* at last just like HTTP://*exapmle.com/*
- Click on +Add a Setting.
- Choose pick a setting and
- Choose Browser Cache TTL
- Select a day or 12 hours from right option
Click again on + Add Setting
- Choose pick a setting and
- Choose Cache Level
- Select Cache everything/standard from right side option

Now you have to +Add new page rule for your Dashboard
- Click new page
- Copy the URL of your website and put /* at last just like Http://*exapmle.com/wp-admin/* ( your dashboard slug )
- Click on +Add a Setting.
- Choose pick a setting and
- Choose Browser Integrity Check
- Make it On

Click again on +Add Setting
- choose Browser Cache TTL
- make it 30 minutes.

Click again on +Add Setting
- Choose pick a setting and
- Choose Always Online
- Make it Off

Click another +Add Setting
- Choose pick a setting and
- Choose Security Level
- Select High to get the high-security level

Click another +Add Setting
- Choose pick a setting and
- Choose Cache Level
- Select Bypass

Click another +Add Setting
- Choose pick a setting and
- Choose Disable Apps

Click another +Add Setting
- Choose pick a setting and
- Choose Disable Performances


Click on Save and Deploy
Let’s make a Last Page Rule for Preview by Clicking the +Add new page rule button.
- Copy the URL of your website and put http://*.exapmle.com/*preview=true*
- Click on +Add a Setting.
- Choose pick a setting and
- Add all the settings as we did for the homepage rule.
- Browser Integrity Check
- Always Online
- Security Level
- Browser Cache TTL
- Cache Level
- Disable Apps
- Disable Performances

Click on Save & Deploy
If you are using WordPress with W3 TOTAL CACHE than you have to change some settings.
- Go to the dashboard of your sites.
- You will see Performance on the left side, hover over it and choose Cloudflare and activate it.
- After that, you need to specify account credentials. ( sign in with same mail as registered in Cloudflare and you will get your API key token in Cloudflare Dashboard on overview section on the bottom right page )
- After that copy your Global API key and paste over the credentials.
1 Comments