Best Cloudflare Settings for WordPress, 3 Page Rules to Use

To get most of your Cloudflare account, you need to configure it carefully for WordPress. WordPress caching plugins are great, but nothing beats an edge cache when it comes to site speed.
If you don’t have a Cloudflare account, create your free account here.
Here are the recommended Cloudflare settings for WordPress.
1. Add Your Site to Cloudflare

Enter your site domain and click “Add site”

Select “Free” plan if you require basic protection
2. Speed Settings for WordPress

From sidebar menu go to Caching – Configuration

Set Caching Level to “:Ignore query string”, Browser Cache TTL to “Respect Existing Headers”
“Respect Existing Headers” setting is required for full caching to work. But you should also have a WordPress caching plugin installed on your site for this to work properly. Most of the caching directives are created and managed by our caching plugin.
3. Page Rules for WordPress

Go to Rules – Page Rules using sidebar menu

Cloudflare recommended page rules for WordPress
Since WordPress is a dynamic application, we need to make sure dynamic pages are not cached. But all static pages and posts should be cached at maximum levels.
Here are the recommended rules for the general audience:
Rule1. Do not cache preview links
URL: example.com/*preview=true*
Cache Level: Bypass
Rule2. Do not cache wp-admin
URL: example.com/wp-admin/*
Cache Level: Bypass
Rule3. Cache everything else
URL: example.com/*
Cache Level: Cache Everything
Edge Cache TTL: a month (this can be purged, keep it long)
Browser Cache TTL: 24 days (pick according to your content update frequency, but keep it as high as possible)
One small note here. When you use those rules for caching everything on the CDN side, your login page will ask for your username and password twice, because the initial page will be served from the CDN cache.
Conclusion
Cloudflare is one of the best CDN alternatives to use with WordPress websites. Its free plan enables edge caching on your site while also protecting it from hackers and bot attacks.
When you use edge caching and cache warming wisely, your site will start climbing up on search engines, and it will also make your users happy.