AWS SNS workaround for 100,000 topics limit
Master System Design with Codemia
Enhance your system design skills with over 120 practice problems, detailed solutions, and hands-on exercises.
Introduction
If you are approaching the Amazon SNS topic quota, the right answer is usually architectural rather than procedural. You can request a quota increase, but in many systems the better long-term fix is to reduce topic cardinality and move routing logic into message attributes, subscriptions, queues, or downstream consumers.
First: Confirm Whether You Need More Topics or Fewer Routing Dimensions
A common anti-pattern is creating one topic per tenant, user, or fine-grained event type when SNS filtering could have handled the same fan-out with far fewer topics.
Before creating more topics, ask:
- Is each topic really a distinct broadcast boundary?
- Could one topic plus filter policies replace hundreds or thousands of narrow topics?
- Are you encoding routing in the topic name that should instead live in message attributes?
That design review often saves more effort than any quota request.
Use Fewer Topics with Subscription Filter Policies
SNS subscription filter policies are one of the best ways to reduce topic count. Instead of creating a separate topic for each category, publish to a broader topic and let subscribers filter what they receive.
Producer example in Python with message attributes:
A subscriber can then filter on tenant, eventType, or both, which removes the need for many separate topics.
Fan Out to SQS and Route Downstream
If subscribers need different processing paths, another scalable pattern is:
- publish to a smaller number of SNS topics
- subscribe SQS queues
- perform fine-grained routing in workers consuming those queues
This reduces topic explosion while preserving isolation and retry behavior at the worker level.
It is often a better fit than creating massive numbers of SNS topics solely to represent routing permutations.
Partition by Account or Region Only When It Reflects Real Boundaries
Splitting traffic across AWS accounts or regions can help with quota management, but it should reflect operational boundaries, compliance requirements, or blast-radius goals, not just quota avoidance.
If the only reason for multi-account design is “we created too many topics,” that is usually a sign the topic model needs simplification first.
Request a Quota Increase When the Model Is Sound
Sometimes the architecture really does need many topics. In that case, request a quota increase through AWS Service Quotas or the relevant support workflow.
That is appropriate when:
- the topic model is already justified
- subscription filtering cannot collapse the design cleanly
- the growth is expected and operationally manageable
A quota increase is a valid tool, but it works best after the design itself has been reviewed.
When SNS Is the Wrong Abstraction
If the system needs durable per-recipient mailboxes, replay, complex routing, or event archive semantics, SNS topics may not be the cleanest primitive to multiply indefinitely.
Depending on the use case, alternatives might include:
- EventBridge for rule-based event routing
- SQS for queue-per-workload patterns
- an application-level routing table stored in a database
- a multi-tenant event processor that uses metadata instead of topic-per-entity design
The quota is sometimes the signal that the abstraction should change.
Common Pitfalls
The most common mistake is creating one topic per tiny routing distinction when subscription filters could have handled the same need more simply.
Another issue is assuming quota increase is the only answer. It may solve the symptom while leaving an unnecessarily high-cardinality design in place.
People also push routing complexity into topic names instead of structured message attributes. That makes the system harder to evolve.
Finally, do not adopt multi-account or multi-region partitioning casually. It adds operational complexity and should serve a real boundary, not just hide an avoidable topic explosion.
Summary
- Start by reducing topic cardinality before treating the SNS topic quota as a pure limit problem.
- Use message attributes and subscription filter policies to replace many narrow topics with fewer broader ones.
- Fan out to SQS and route downstream when consumers need finer control.
- Request a quota increase only after confirming the topic model is justified.
- If the routing problem is more complex than broadcast plus filtering, reconsider whether SNS topics are the right primary abstraction.

