Articles on: Getting Started

Cloudflare Integration: Full Setup Guide

WP Compress integrates with Cloudflare to provide automated cache purging and uninterrupted access, ensuring your website stays optimized and up to date without manual intervention.


The API token is set up once at the account level. Once connected, all zones across your Cloudflare account will appear in the WP Compress dropdown — you simply select the site you want to link each time, no additional token setup required. If you'd like to restrict the token to a specific domain only, you can do so during setup.



Step 1: Generate an API Token


  1. Log in to Cloudflare
  2. Click your profile icon in the top right and select My Profile
  3. Navigate to the API Tokens tab
  4. Click Create Token



  1. Click Create Custom Token




Step 2: Configure the API Token


  1. Configure the token permissions as shown below



  1. Save your settings — it should look like this



If you'd like to restrict this token to a specific domain rather than your entire account, specify the zone under the Zone Resources section before saving.


  1. Copy your token and store it somewhere safe



This is the only time your token will be displayed. Copy it before closing this screen.



Step 3: Connect to WP Compress


  1. Navigate to your WP Compress settings
  2. Locate the Cloudflare Integration section
  3. Paste the API token and click Connect
  4. Select the zone you want to link from the dropdown
  5. Click Connect — the page will update once the connection is confirmed


Once connected, WP Compress will automatically purge the Cloudflare cache whenever optimizations are applied. To link additional sites, simply return to the Cloudflare Integration section, select a new zone, and connect — no new token needed.



Need Help?


If you run into any issues during setup, our support team is available 24/7 via live chat. You can also refer to the Cloudflare API documentation for token configuration details.

Updated on: 03/03/2026

Was this article helpful?

Share your feedback

Cancel

Thank you!