Send messages

Put a message on a queue, or up to ten in one request, with attributes, a delay, or a FIFO message group.

Last updated 18 November 2026View as Markdown

Replace my-queue with the name of your queue.

A message has a body of text (not empty; no control characters other than tab, line feed and carriage return) and up to 10 attributes, name–value string pairs whose names are letters, digits, _, . or -. Its size is the body plus the attributes' names and values in UTF-8 bytes, and must not exceed the queue's maximum message size (256 KiB on a new queue).

Prerequisites

  • Permission for queue:SendMessage on the queue. The batch send needs the same action. For the console, also queue:GetQueueAttributes on it, to open its page.

Send a message

  1. Open the queue, then choose Send and receive (or Send a message at the top of the queue's page).
  2. Under Send a message, for Body, enter the message.
  3. (Optional) For Attributes, enter one key=value per line, up to ten.
  4. On a standard queue, for Delay, enter the seconds before the message can be received (0 to 900). The field starts at 0 and is always sent, so a console send does not use the queue's delivery delay unless you enter it here. On a FIFO queue, for Message group, enter the group, and for Deduplication id, enter an id (optional when the queue has content-based deduplication).
  5. Choose Send.

The section shows Sent with the message id, and on a FIFO queue its sequence number. A FIFO send that repeats a recent deduplication id shows Duplicate of the original message instead.

To send from an SQS client, use SendMessage or SendMessageBatch; see Use an SQS client.

Result

The message is stored and can be received once its delay, if any, has passed. A delay given with a send overrides the queue's delivery delay for that message.

When a send is refused

  • 400 "Message is 70000 bytes; this queue accepts at most 65536." when the message is larger than the queue's maximum message size (here set to 64 KiB). In a batch, that entry fails alone.
  • 400 "The batch is 300000 bytes; a batch may carry at most 262144." when the messages of one request together exceed 256 KiB, a single message over 256 KiB included. The whole batch is refused.
  • 403 with code OverLimit when the queue would hold more than 100,000 messages, or your organization's queues more than 1 GiB of messages. The whole batch is refused. The counts are a few seconds old, so a burst can go slightly over before sends are refused. See Quotas.
  • 400 "MessageDeduplicationId applies only to FIFO queues." on a standard queue. A message group is ignored there.
  • On a FIFO queue: 400 "The request must contain the parameter MessageGroupId." without a group; "DelaySeconds is not valid per message on a FIFO queue; set the delay on the queue instead." with a delay; and "The queue should either have ContentBasedDeduplication enabled or MessageDeduplicationId provided explicitly." without a deduplication id on a queue without content-based deduplication.
Did this page help you?