Cloudflare Docs
Visit Analytics on GitHub
Set theme to dark (⇧+D)


Use Rules to configure whether to track Web Analytics for specific websites or paths. If you do not configure any rules, Web Analytics injects the JavaScript (JS) snippet for all sites.

Rules are only available for sites proxied through Cloudflare. For more information, refer to Limits.

  1. Log in to the Cloudflare dashboard, and select your account.
  2. Select the Analytics & Logs drop-down and choose Web Analytics.
  3. Find the site you want to configure and select Manage site.
  4. Select Advanced options > Add rule.
  5. Select the Action and fill in the hostname and path(s) you want to add a rule for.
  6. If you want to add additional rules, select Add rule. Otherwise select Update to save the rule.