Rules
Use Rules to configure whether to track Web Analytics for specific websites or paths. By default, Web Analytics automatically creates a single rule for the zone that injects the JavaScript (JS) snippet for all pages.
Rules are only available for sites proxied through Cloudflare. For more information, refer to Limits.
-
In the Cloudflare dashboard, go to the Web Analytics page.
Go to Web analytics -
Find the site you want to configure and select Manage site.
-
Select Advanced options > Add rule.
-
Select the Action and fill in the hostname and path(s) you want to add a rule for.
-
If you want to add additional rules, select Add rule. Otherwise select Update to save the rule.
Was this helpful?
- Resources
- API
- New to Cloudflare?
- Directory
- Sponsorships
- Open Source
- Support
- Help Center
- System Status
- Compliance
- GDPR
- Company
- cloudflare.com
- Our team
- Careers
- © 2025 Cloudflare, Inc.
- Privacy Policy
- Terms of Use
- Report Security Issues
- Trademark