Support Home > Getting Started > Use Jetpack and Cloudflare on your WordPress site

Use Jetpack and Cloudflare on your WordPress site

Here are a few steps to follow to configure Cloudflare on your site, before installing the Jetpack plugin.

Cloudflare is a popular CDN, caching, and protection service. It can be used with WordPress and is compatible with Jetpack.

Jetpack communicates with your website through the secure use of your xmlrpc.php file. By default, Cloudflare blocks all non-Jetpack access to this file and serves an “HTTP 403 Forbidden” message. This is designed to block access to that file by unwarranted users.

Cloudflare has settings in place to make sure that Jetpack requests to the xmlrpc.php file are allowed to pass through their firewalls and protection services. This means you should not have to manually configure access for Jetpack through Cloudflare.

You can know more about Cloudflare and Jetpack in this article.

The steps below help to ensure that your site is optimized to work well with Cloudflare.

To get started, you’ll want to follow the instructions to add your site to Cloudflare.

Create a PageRule to exclude WordPress’ dashboard from Cloudflare.

While Cloudflare is useful for your readers, you do not need to use it for your site’s dashboard. It may in fact cause some issues. Luckily, you can set up rules so Cloudflare ignores your site’s dashboard.

  1. Go to “Rules” in your Cloudflare dashboard.
  2. Under “Add New Rule”, enter the following: **
  3. Make sure caching, apps, and performance are disabled.
  4. Save your changes.

Use Cloudflare’s SSL certificate on your site.

  1. Under the SSL/TLS menu, enable one of Cloudflare’s SSL options.
  1. Wait for the changes to be available on your site.
  2. Install and activate the Cloudflare plugin.
  3. Install the Cloudflare Flexible SSL plugin to avoid running into Redirect loop issues in your dashboard.
  4. Enable Administration over SSL (reference) by adding the following to wp-config.php:
     * Admin over SSL
    define('FORCE_SSL_ADMIN', true);
  5. Set the port to 443 by adding the following to wp-config.php:
     * Set port to 443
    $_SERVER['SERVER_PORT'] = 443;
  6. Under Settings > General in your dashboard, change both your site address and WordPress address to use HTTPS.
  7. In your Cloudflare settings, create a Page Rule to redirect all traffic from HTTP to HTTPS.

You should then be all set, now install the Jetpack plugin!

Pause Cloudflare

For testing purposes, you can temporarily pause Cloudflare by:

  1. Going to the Overview tab in the Cloudflare dashboard.
  2. At the bottom right of this page there is a link under Advanced Actions .
  3. Click Pause Cloudflare on Site

More information is in this Cloudflare article.

Troubleshooting Jetpack and Cloudflare

  • Table Of Contents

  • Categories

  • Contact Us

    Need more help? Feel free to contact us.