Work with custom rulesets in the dashboard
Last updated Oct 16, 2026 Notes
Custom rulesets at the account level require an Enterprise plan.
For instructions on creating and deploying a custom ruleset at the zone level, refer to Custom rulesets (zone level).
Quota limits
Account-level custom rulesets have the following quota limits:
- Maximum rulesets: 10
- Maximum rules per ruleset: 100
- Total rule quota: 1,000 rules across all rulesets on the request path
The total rule quota of 1,000 rules is a hard limit that applies to all plans and cannot be increased. This limit applies across all rulesets that a request traverses, not just account-level custom rulesets.
Redistribute rules across rulesets
If you need to change the distribution of rules across your rulesets (for example, to create fewer rulesets with more rules per ruleset), contact Cloudflare Support. Only Cloudflare Support can update account-level entitlements to change the ruleset and rule distribution.
Before contacting Support, consider the following optimizations:
- Consolidate rules: Combine rules with similar conditions or actions into a single rule with broader matching criteria.
- Remove unused rules: Audit your rulesets and remove rules that are no longer triggering or are duplicating functionality.
- Use IP lists: Instead of creating multiple rules for individual IP addresses, use IP lists to group IPs and reference them in a single rule.
Create and deploy a custom ruleset
To create and deploy a custom ruleset at the account level:
- In the Cloudflare dashboard, go to the WAF page. Go to WAF ↗
- Go to the Custom rulesets tab.

- To create a new empty ruleset, select Create ruleset. To duplicate an existing ruleset, select the three dots next to it > Duplicate.
- In the page that displays, enter a name and (optionally) a description for the custom ruleset.
- Under Scope, define when the custom ruleset should run.
- Select All incoming requests to apply the custom ruleset to all incoming requests for all your zones on an Enterprise plan.
- Select Custom filter expression to define a custom expression that defines when to execute the custom ruleset. Use the Field drop-down list to choose an HTTP property. For each request, the value of the property you choose for Field is compared to the value you specify for Value using the operator selected in Operator. Alternatively, select Edit expression to define your expression using the Expression Editor.
Caution
Custom rulesets deployed at the account level only apply to incoming traffic of Enterprise domains. The Expression Builder will automatically include this filter. If you define a custom expression for the ruleset using the Expression Editor, you must use parentheses to enclose any custom conditions and end your expression with and cf.zone.plan eq "ENT" so that the rule only applies to domains on an Enterprise plan.
6. To create a new rule, select Add rule.
7. Enter a descriptive name for the rule in Rule name.
8. Under When incoming requests match, use the Field drop-down list to choose an HTTP property. For each request, the value of the property you choose for Field is compared to the value you specify for Value using the operator selected in Operator. Alternatively, select Edit expression to define your expression using the Expression Editor.
9. Select the rule action from the Choose action drop-down list. For example, selecting Block tells Cloudflare to refuse requests that match the conditions you specified.
10. (Optional) If you selected the Block action, you can configure a custom response.
11. Select Deploy.
12. Add other rules to the custom ruleset, if needed. You can also duplicate an existing rule in the custom ruleset.
13. Select Create.
Edit a custom ruleset
- In the Cloudflare dashboard, go to the WAF page. Go to WAF ↗
- Go to the Custom rulesets tab.

- To edit a custom ruleset, select the three dots next to it > Edit.
- Make any desired changes to the ruleset by selecting Edit next to the items you want to change.
- When you are done, select Back to rulesets list.
Caution
Custom rulesets deployed at the account level only apply to incoming traffic of Enterprise domains. The Expression Builder in the Cloudflare dashboard will automatically include this filter. If you define a custom expression for the ruleset using the Expression Editor, you must use parentheses to enclose any custom conditions and end your expression with and cf.zone.plan eq "ENT" so that the rule only applies to domains on an Enterprise plan.
Delete a custom ruleset
- In the Cloudflare dashboard, go to the WAF page. Go to WAF ↗
- Go to the Custom rulesets tab.
- To delete a custom ruleset, select the three dots next to it > Delete.
- To confirm the delete operation, select Delete.
Configure a custom response for blocked requests
When you select the Block action in a rule you can optionally define a custom response.
The custom response has three settings:
- With response type: Choose a content type or the default WAF block response from the list. The available custom response types are the following:
| Dashboard value | API value |
|---|---|
| Custom HTML | "text/html" |
| Custom Text | "text/plain" |
| Custom JSON | "application/json" |
| Custom XML | "text/xml" |
| - With response code: Choose an HTTP status code for the response, in the range 400-499. The default response code is 403. | |
| - Response body: The body of the response. Configure a valid body according to the response type you selected. The maximum field size is 2 KB. |
Was this helpful?
YesNo
On this page
{"@context":"https://schema.org","@type":"TechArticle","@id":"https://developers.cloudflare.com/waf/account/custom-rulesets/create-dashboard/#page","headline":"Work with custom rulesets in the dashboard","description":"Create and manage account-level custom rulesets in the dashboard.","url":"https://developers.cloudflare.com/waf/account/custom-rulesets/create-dashboard/","inLanguage":"en","image":"https://developers.cloudflare.com/waf/account/custom-rulesets/create-dashboard/og.png?v=5a62cfe5159cd803","dateModified":"2026-10-16","publisher":{"@type":"Organization","name":"Cloudflare","description":"One platform for your apps, agents, and workforce. Build, secure, and scale without managing infrastructure","url":"https://www.cloudflare.com/","sameAs":["https://github.com/cloudflare","https://www.linkedin.com/company/cloudflare","https://x.com/cloudflare"],"logo":{"@type":"ImageObject","url":"https://developers.cloudflare.com/logo.svg"},"address":{"@type":"PostalAddress","streetAddress":"101 Townsend St","addressLocality":"San Francisco","addressRegion":"CA","postalCode":"94107","addressCountry":"US"},"contactPoint":[{"@type":"ContactPoint","contactType":"Customer Support","url":"https://support.cloudflare.com/","availableLanguage":["English"]},{"@type":"ContactPoint","contactType":"Sales","url":"https://www.cloudflare.com/contact/","availableLanguage":["English"]}]},"isPartOf":{"@type":"WebSite","@id":"https://developers.cloudflare.com/#website","name":"Cloudflare Docs","url":"https://developers.cloudflare.com/"}}
description: Deploy and manage WAF managed rulesets at the account level. title: Managed rulesets image: https://developers.cloudflare.com/waf/account/managed-rulesets/og.png?v=5ff9473f5fbb3fb3
Documentation Index
Fetch the complete documentation index at: https://developers.cloudflare.com/waf/llms.txt
Use this file to discover all available pages before exploring further.
