These two messaging services get compared constantly. The distinction is pull vs push, one consumer vs many.

Queue vs pub/sub

SQS is a queue: messages wait until one consumer group pulls and processes them — for decoupling and buffering work. SNS is pub/sub: a message is pushed to all subscribers at once — for fan-out notifications. Need to buffer work for a worker? SQS. Need to notify many systems from one event? SNS. They combine well: SNS fans out into multiple SQS queues.

How the two services work together

Use Amazon SQS when producers and consumers should be decoupled: a producer places a message on a queue, and a consumer polls the queue and processes the message. The queue can absorb bursts so the worker can process messages at a sustainable rate. Configure visibility timeout, retries, and a dead-letter queue according to the workload so repeatedly failing messages do not block normal processing.

Use Amazon SNS when one published message should be delivered to multiple subscribers. Subscribers can include endpoints such as SQS queues, Lambda functions, or HTTPS endpoints. A common fan-out pattern is to publish one event to SNS and deliver a copy to several SQS queues, allowing separate consumers to process the event independently.

Common exam traps

Official references: Amazon SQS and Amazon SNS.

Test yourself

Practice question

You need to decouple a web tier from a backend worker so requests are buffered and processed one at a time at the worker’s pace. Which service?

  1. Amazon SNS
  2. Amazon SQS
  3. Amazon EventBridge
  4. Amazon Kinesis
👉 Click to reveal the answer & explanation

Correct answer: B. SQS buffers messages in a queue for a consumer to pull and process at its own pace — classic decoupling. SNS (A) pushes to all subscribers at once; EventBridge (C) routes events by rules; Kinesis (D) is for streaming data.

Related topics

Amazon SQS · Amazon SNS · Amazon EventBridge

CloudExamPro Premium

Ready to pass your AWS exam?

Stop guessing whether you’re ready. Our full-length, exam-realistic practice exams put you through the exact question style you’ll face — with a detailed explanation behind every answer, so you learn why, not just what.

  • ✓  6 full-length practice exams
  • ✓  A detailed explanation for every single question
  • ✓  Realistic, scenario-based questions — not memory dumps
  • ✓  6 months of access to your selected certification pack

See the Practice Exam Packs → or try 25 free SAA-C03 questions first