AWS Cost Categories rejects new rules - the rule limit is reached and attribution rules stop applying
Fixes AWS Cost Categories when new rules are rejected at the limit. Covers auditing existing rules, merging overlapping rules with regex, and deleting stale rules. Use when rule creation is refused. Not for rules that exist but do not match.
TL;DR
Cost Categories have a fixed rule limit per category, and you have hit it, so new attribution rules are rejected. Audit the existing rules, merge overlapping ones with regex matches, delete the stale ones, and the new rules will fit.
Use this when
- Creating a cost category rule errors on the limit.
- Attribution stopped improving because new rules cannot be added.
- The category has grown rule by rule over many months.
Not for this skill when
- Rules exist but do not match the intended costs. That is a rule-logic problem.
- You need more dimensions than categories support. That is a design problem.
Steps
- List the rules on the category and sort by last-effective date or match volume. Verify: you can see which rules actually categorize spend.
- Delete rules for retired services, old projects, and one-off investigations. Verify: the rule count drops.
- Merge overlapping rules: several exact-match rules on similar tag values become one regex rule. Verify: the merged rule categorizes the same spend (spot-check a month).
- Retry creating the new rule. Verify: it is accepted.
- Set a periodic review: rules for temporary projects should carry an expiry note. Verify: the next review is scheduled.
Regex merge example pattern
Five rules matching team-a through team-e become one rule matching the team tag against a pattern covering all five. Verify: unallocated spend does not increase after the merge.
Compatibility: AWS Cost Categories, payer and linked account views.
Why it happens
Rule limits are per category, and teams add rules incrementally without ever removing them. Each rule feels cheap, so the category fills up with dead rules until the limit blocks the one rule you actually need.
Edge cases / pitfalls
- Rule order matters; merging changes evaluation order, so test before deleting originals.
- Deleted rules take effect on new data; historical categorized data is not reprocessed the same way.
- The default uncategorized value catches what no rule matches. Watch it after a merge.
- Split billing and shared costs interact with rules; verify the merge against those line items.
Provenance
Resolved from the public thread: https://vectle.com/posts/pstguaTIucgZljBZd4jhnP-g