Before sending text messages, understand the content length limits and sending frequency limits.
Rules for calculating message length
Message length (in characters) = Number of characters in the SMS signature + Number of characters in the SMS template. The message content cannot exceed 500 characters.
The character count of an SMS signature includes the
【】or[]symbols that the system automatically adds when sending a message.The character count of the SMS template is based on the actual content of the received message.
Message type | Length calculation rules | |
Domestic SMS | Simplified Chinese characters, letters, numbers, and punctuation marks are all counted as one character, regardless of whether they are full-width or half-width. If a message is 70 characters or less, it is billed as one message. If it is longer than 70 characters, it is a long message and is split and billed as multiple messages based on 67 characters per message. Example: A message with 160 characters is split into three messages of 67, 67, and 26 characters, and is billed as three messages. | |
International / Hong Kong, Macau, and Taiwan SMS | Pure English messages (GSM-7 encoding) | Standard characters such as letters and numbers are counted as one character. Extended characters are counted as two characters. Extended characters include the following: If a message contains other unlisted extended characters, the entire message is calculated based on the rules for other languages (UCS-2 encoding), regardless of its length or whether it is split. If a message is 160 characters or less, it is billed as one message. If it is longer than 160 characters, it is a long message and is split and billed as multiple messages based on 153 characters per message. The signature for pure English messages uses Example: A message with 350 characters is split into three messages of 153, 153, and 44 characters, and is billed as three messages. |
Messages in other languages (UCS-2 encoding) | Chinese characters, letters, numbers, symbols, and spaces are all counted as one character. If a message is 70 characters or less, it is billed as one message. If it is longer than 70 characters, it is a long message and is split and billed as multiple messages based on 67 characters per message. Example: A message with 150 characters is split into three messages of 67, 67, and 16 characters, and is billed as three messages. | |
Sending frequency limits
The following rules apply only to messages sent to the Chinese mainland. They do not apply to Hong Kong (China), Macao (China), Taiwan (China), or other countries and regions.
Users may frequently request verification codes or use text messages to reset passwords. To prevent malicious API calls, Alibaba Cloud imposes limits on message sending.
Domestic SMS service
Message type | Sending limit description |
Verification code |
|
Notification | You can use the same signature and SMS template code to send a maximum of 50 notifications per day to the same mobile phone number. |
Promotional message | You can use the same signature and SMS template code to send a maximum of 50 promotional messages per day to the same mobile phone number. |
The limits of "1 per minute" and "5 per hour" are based on fixed time windows. These windows align with the clock minute and hour in the UTC+8 time zone. For example, 14:03:00 to 14:03:59 is a one-minute window. The limits are not based on a tumbling window that starts when you send a message.
A day is a 24-hour period that starts when a message is sent. For example, if you send a message at 11:00 on August 24, 2017, the system checks the daily limits (40 for verification codes, 50 for notifications, and 50 for promotional messages) until 11:00 on August 25, 2017.
A message counts toward the sending limit as soon as it is submitted. A submission is successful if you add a sending task in the console or make a successful API request. This applies regardless of whether the message is delivered.
What to do if you reach a sending limit
You can add phone numbers to a whitelist.
Numbers on the whitelist are not subject to sending frequency limits. You can add up to 300 numbers. For more information, see Set up an SMS whitelist.
The exemption from throttling for whitelisted numbers applies only to Short Message Service. You must also consider throttling limits from carriers.
Enterprise users can adjust throttling limits. Go to the Sending Frequency Settings page in the Short Message Service console. For more information, see Set the SMS sending frequency.
Individual users cannot adjust throttling limits.
If the daily API throttling limit is triggered, the restriction is automatically removed after 24 hours. You can then resend the request. Or, you can upgrade your current account to an enterprise account. For more information, see How to upgrade an individual account to an enterprise account.
If you reach the hourly limit, wait one hour and then send the message again.
If you receive a service throttling error, adjust your API call schedule or reduce your sending frequency to comply with the limit.