Skip to content

Limits and validation

API limits

LimitValueError code
Maximum tags per account10,000 (beta)N/A
Maximum tag key length256 characters1011
Maximum tag value length1,024 characters1012
Maximum tag filters per query201010
Maximum OR values per filter101013
Results per page100 (fixed)N/A

When a limit is exceeded, the API returns 400 Bad Request with the corresponding error code.

During the beta, each account is limited to 10,000 total tags. If you need a higher limit, contact Cloudflare support.

Case sensitivity

Tag keys and values are case-sensitive. Environment, environment, and ENVIRONMENT are treated as three distinct keys. Be consistent with casing conventions across your organization to avoid duplicate keys.

Tag key validation

Tag keys must follow these character rules:

Allowed

  • Unicode letters (any language)
  • Unicode digits (0-9)
  • Underscores (_)
  • Periods (.)
  • Hyphens (-)

Not allowed

  • Empty strings
  • Spaces
  • Special characters (except _, ., -)

Examples

KeyValidReason
environmentYesLetters only
team_nameYesUnderscore
cost-centerYesHyphen
owner.emailYesPeriod
env123YesLetters and digits
env nameNoContains space
team@workNoSpecial character @
(empty)NoEmpty string

Invalid tag keys return 400 Bad Request with error code 1014.

Pagination

List endpoints use cursor-based pagination with a fixed page size of 100. The page size is not configurable.

Paginated endpoints:

  • GET /accounts/{account_id}/tags/keys
  • GET /accounts/{account_id}/tags/resources
  • GET /accounts/{account_id}/tags/values/{tag_key}

Refer to Filter resources by tag for pagination examples.