How to Make the Most of the Free Cloudflare Plan for WordPress

How to Make the Most of the Free Cloudflare Plan for WordPress

Cloudflare’s free plan gives a WordPress site real gains in speed and security, as long as you set a few things up yourself. The big wins are Full (strict) SSL, a cache rule (or plugin) that serves pages to logged-out visitors from Cloudflare’s edge, and a handful of WAF custom rules around the login page. Some older tips you’ll still see online, like Auto Minify and the “Brotli” toggle, don’t apply any more.

Everything below is based on Cloudflare’s own documentation. Cloudflare changes its free plan often, so if your dashboard looks different, trust the dashboard over any blog post, including this one.

What the Free Plan Includes for a WordPress Site

According to Cloudflare’s plans page and docs, a free zone gets:

Feature Free plan
CDN and unmetered DDoS protection Included
Universal SSL certificate Included
WAF with the free managed ruleset Included
WAF custom rules 5 rules (no regex)
Rate limiting rules 1 rule (10-second counting window, counted per IP)
Cache Rules 10 rules
Page Rules 3 rules, but Cloudflare now marks Page Rules as deprecated
Bot Fight Mode Included
Turnstile (CAPTCHA alternative) Free, up to 20 widgets
Rocket Loader Included
Automatic Platform Optimization (APO) Paid add-on on Free, included on Pro and above

1. Connect Your Site and Pick a Plugin

Add your domain in the Cloudflare dashboard, check that your DNS records were imported correctly, and switch your domain’s nameservers to the two Cloudflare gives you. Records with the orange cloud (proxied) go through Cloudflare. Grey-cloud records bypass it.

On the WordPress side, there are two plugins worth knowing about:

  • The official Cloudflare plugin handles automatic cache purging when you update content, applies WordPress-friendly default settings, and is required if you buy APO.
  • App for Cloudflare is a third-party plugin. Its free version can cache HTML pages for guests at Cloudflare’s data centers on any plan, including Free, without APO. It also purges the cache, fixes Flexible SSL redirect loops, shows real visitor IPs and adds Turnstile to login and comment forms.

App for Cloudflare plugin settings showing the “Cache pages for guests” toggle switched on with a 6-hour cache time

The screenshot above is App for Cloudflare’s guest page caching switch. On a free plan, this is the simplest way to get full-page caching without writing rules yourself. The plugin also notes that making a page eligible for caching doesn’t guarantee it will always be served from cache.

2. Get SSL/TLS Right

In SSL/TLS > Overview, Cloudflare now defaults new zones to Automatic SSL/TLS, which picks the most secure mode your server supports. If you set it manually, choose Full (strict). Cloudflare “strongly recommends” Full or Full (strict). Full (strict) checks your server’s certificate, and either a Let’s Encrypt certificate or a free Cloudflare Origin CA certificate will do.

Avoid Flexible. It encrypts only the visitor-to-Cloudflare leg, and with WordPress it’s the classic cause of “too many redirects” loops.

Then, under SSL/TLS > Edge Certificates, turn on:

  • Always Use HTTPS: redirects every HTTP request to HTTPS. Cloudflare warns against also redirecting at your server, because that can cause redirect loops. If a security plugin or .htaccess rule already forces HTTPS, pick one.
  • Automatic HTTPS Rewrites: fixes many mixed-content warnings by rewriting http:// links to https:// where the resource is available over HTTPS. It can’t fix everything, such as resources your theme’s JavaScript loads over HTTP. The real fix is updating old URLs in your database.

3. Cache Your HTML With Cache Rules, Not Page Rules

By default, Cloudflare caches static files like images, CSS and JS, but not your HTML pages. The old trick was a “Cache Everything” Page Rule. Page Rules are now deprecated, and the replacement is Cache Rules. You get 10 on the free plan.

If you’d rather not use a plugin for guest caching, create a cache rule under Caching > Cache Rules with Cache eligibility: Eligible for cache and a custom expression like this:

(http.host eq "example.com"
 and not http.request.uri.path contains "/wp-admin"
 and not http.request.uri.path contains "/wp-login.php"
 and not http.request.uri.path contains "/wp-json"
 and not http.cookie contains "wordpress_logged_in"
 and not http.cookie contains "comment_author"
 and not http.cookie contains "wp-postpass")

The path exclusions keep the dashboard, login page and REST API uncached. The cookie exclusions skip signed-in users (otherwise strangers could see a cached admin bar), commenters and password-protected posts. If you run WooCommerce, also exclude /cart, /checkout and /my-account, plus the woocommerce_items_in_cart cookie. Set an Edge TTL that suits how often you publish. Then make sure something purges the cache when you update a post. Both plugins above can do that. Without purging, visitors see stale pages until the TTL runs out.

4. APO: Worth It, but Not Free

Automatic Platform Optimization caches your whole WordPress site at Cloudflare’s edge. It’s included on Pro, Business and Enterprise, but on the Free plan it’s a paid add-on, and you need the official Cloudflare plugin to use it. (My earlier version of this post said APO works free with the plugin. That was wrong.)

If the guest caching above already works for you, APO is optional rather than essential.

5. Speed Settings That Still Exist

  • Rocket Loader (all plans) defers your JavaScript until after the page renders. It can help script-heavy themes, but Cloudflare’s own advice is to turn it off and retest if you see JavaScript or jQuery problems. Test sliders, forms and checkout pages after enabling it.
  • Compression happens automatically. On the Free plan, Cloudflare compresses with Zstandard by default when the visitor’s browser supports it, so there’s no Brotli switch to hunt for any more.
  • Auto Minify is gone. Cloudflare retired it on 5 August 2024. If you want minified CSS and JS, let your caching plugin (WP Rocket, LiteSpeed Cache, W3 Total Cache and similar) do it.

6. Security: Custom Rules, Rate Limiting and Bots

Your free plan includes the managed WAF ruleset automatically. The five custom rules (Security > WAF > Custom rules) are where you can tailor protection for WordPress. Three that work well:

Rule 1 – Block XML-RPC (action: Block)
(http.request.uri.path eq "/xmlrpc.php")

Rule 2 – Challenge the login page except from your IP (action: Managed Challenge)
(http.request.uri.path eq "/wp-login.php" and not ip.src in {203.0.113.10})

Rule 3 – Challenge wp-admin from outside your country (action: Managed Challenge)
(http.request.uri.path contains "/wp-admin"
 and not http.request.uri.path contains "/wp-admin/admin-ajax.php"
 and not ip.src.country in {"PL"})

Replace the example IP and country code with your own. Before blocking XML-RPC, check whether anything you use still needs it. Jetpack and some mobile publishing apps are the usual suspects. In rule 3, leave admin-ajax.php out, because many themes and plugins call it from the public side of the site.

Use your single rate limiting rule on /wp-login.php. On Free, the rule counts requests per IP over a fixed 10-second window, and it can only match on the request path (plus verified bots). That’s still enough to slow down password-guessing bots.

Bot Fight Mode is a free one-click toggle that challenges traffic matching known bot patterns. Two caveats from Cloudflare’s docs. First, WAF skip rules can’t bypass it. Second, it may challenge API or app traffic. If an uptime monitor, app or payment callback stops working after you enable it, turning it off is the only fix.

Security Level works differently than old guides describe. In the current dashboard it’s essentially the switch for Under Attack mode. That mode shows an interstitial challenge to every visitor, so keep it for when you’re actually being flooded.

Finally, consider Turnstile on your login, registration and comment forms. It’s free, and App for Cloudflare can add it for you.

7. Check Analytics and Adjust

Every so often, check the cache hit ratio in Analytics to confirm your cache rule is working, and Security Events to see what your custom rules catch, including any real visitors caught by mistake.

If you like keeping your site lean, my guide to an automatic image slider in pure HTML and CSS is a good next read. If you’re producing content for WordPress, see my Koala Writer vs ChatGPT comparison.

FAQ

Is Cloudflare APO free?

No. It’s included on Pro, Business and Enterprise, and it’s a paid add-on on the Free plan. You can still get guest page caching for free with a cache rule or the App for Cloudflare plugin.

Which SSL mode should I use for WordPress on Cloudflare?

Full (strict), with a Let’s Encrypt or Cloudflare Origin CA certificate on your server, or Automatic SSL/TLS if it picks Full (strict) for you. Avoid Flexible, which commonly causes redirect loops.

Can I still use Page Rules on the free plan?

Free zones still show three Page Rules, but Cloudflare marks Page Rules as deprecated. For caching, new setups should use Cache Rules instead, and you get 10 of them on Free.

Should I use a caching plugin as well as Cloudflare?

Yes, they complement each other. A plugin caches on your server and handles minification. Cloudflare serves cached pages from its edge. Just make sure your plugin purges Cloudflare’s cache when content changes.

Does the free Cloudflare plan include a WAF?

Yes. Free zones get the free managed ruleset, five custom rules (without regex) and one rate limiting rule. That’s enough to cover the WordPress login page, XML-RPC and wp-admin.

More from my guides notes ↓

  1. Guides

    Is Insta360 FlexiCare Worth It?

    Is Insta360 FlexiCare worth it? How the replacement plan works, what it costs per claim, and who should buy it instead of skipping it.

  2. Guides

    TON Wallet or Crypto Wallet? The Key Differences Explained

    TON Wallet vs Crypto Wallet in Telegram explained: custodial vs self-custody, what the apps are called now, Tonkeeper, seed phrase safety and common scams.

  3. Guides

    How to Check the DU Balance: A Simple Guide for Users

    Check your du balance in seconds with the official USSD codes, SMS keywords, the du app and My Account, plus how postpaid users see bills and how One2One works.