---
page_type: error
code: 21611
message: "21611: This 'From' number has exceeded the maximum number of queued messages"
level: ERROR
product: Programmable SMS
---

## Description

Twilio queues messages based on the sending rate of a sender or an account. For example a US long code number can send one message [segment](https://www.twilio.com/blog/what-the-heck-is-a-segment.html) per second, and a short code may send over 100 message segments per second.

Messages can only be queued for 10 hours and then they automatically fail. This queue length limit can be reduced by setting a lower [Validity Period](https://www.twilio.com/en-us/blog/validity-period-promotional-verification-use-cases) within your Messaging Service settings or in your API requests to send messages.

You can monitor the length on your queue via the [Queue Insights dashboard](https://console.twilio.com/us1/monitor/insights/sms?frameUrl=/console/sms/insights/delivery?x-target-region%3Dus1\&currentFrameUrl=/console/sms/insights/delivery?x-target-region%3Dus1%26__override_layout__%3Dembed%26q%3DKGFjdGl2ZUluc2lnaHRzVmlldzpsYXRlbmN5KQ%253D%253D%26bifrost%3Dtrue).

For more information please view this [FAQ](https://support.twilio.com/hc/en-us/articles/115002943027-Understanding-Twilio-Rate-Limits-and-Message-Queues).

When a queue for a particular 'From' number exceeds 10 hours, this error will be thrown when attempting to create additional messages on the same number.

Note: If you are using a Messaging Service and the numbers in the pool experience queue overload, messages will instead fail after creation with [error 30001](/docs/api/errors/30001).

### Possible Causes

You have attempted to enqueue more than 10 hours' worth of messages on a single Twilio phone number or sender (based on that number's [MPS rate limit](https://support.twilio.com/hc/en-us/articles/115002943027-Understanding-Twilio-Rate-Limits-and-Message-Queues)).

### Possible Solutions

- Slow down your sending rate to avoid queuing on your Twilio number.
- Consider using a [Messaging Service](/docs/messaging/services) to better distribute message throughput, if appropriate for your use case.
- Increase your [validity period](/docs/messaging/api/message-resource#create-a-message-resource) if you have it set to lower than 10 hours