SMS pumping: stop bots running up your verification bill
Short answer: If your website or app sends a text message whenever someone types a phone number, for a sign-up code, a login code or an app download link, fraudsters can abuse it. In SMS pumping, bots request messages to blocks of numbers on networks that share the revenue with them, and you pay for every message. Protect the form with per-number, per-IP and per-prefix rate limits, increasing delays between resends, bot checks, country restrictions, line-type lookups, and an alert when the share of codes actually entered drops. Check your SMS provider's own fraud controls too.
What SMS pumping is
Twilio's documentation describes SMS pumping fraud as fraudsters taking advantage of a phone number input field to receive a one-time passcode, an app download link or anything else via SMS. The messages go to a range of numbers controlled by a particular mobile network operator, and the fraudsters get a share of the revenue generated. The operator may be complicit, or may be exploited unknowingly. The documentation notes this fraud is more likely to involve smaller operators.
A related attack, toll fraud or International Revenue Sharing Fraud, uses voice calls instead: an app is exploited to generate a high volume of calls to the fraudster's premium-rate numbers, and the victim bears the cost of each minute.
Twilio's fraud-prevention guide points out that both attacks aim to make money from inflated traffic, not to steal information. That is why small businesses are surprised by them: no data is lost, but the SMS bill can be large.
How to spot an attack
According to Twilio's documentation, typical signs include:
- A spike in messages to blocks of adjacent numbers, all on the same network.
- For one-time passcodes, verifications that are never completed: codes are sent but nobody types them in.
Other common signs are messages to countries where you have no customers, sign-ups at night in bursts, and many requests from the same IP ranges or cloud providers.
Rate limits that actually help
Rate limiting is the first line of defence:
- Per phone number: no more than a few codes per number per hour.
- Per number range or prefix: Twilio recommends ensuring your app will not send more than one message per set number of seconds to the same mobile number range or prefix, which stops the "adjacent numbers" pattern.
- Per user, IP address or device identifier.
- Increasing delays between resends. The guide suggests exponential delays between requests to the same number, and gives the example of showing a "call me instead" option only after three time-delayed SMS attempts, rather than at any time.
The guide is honest that rate limits may not prevent fraud entirely, but they can slow attackers enough that your app is no longer worth the effort.
Make bots work harder
- Use bot detection or a CAPTCHA on forms that send texts, ideally an invisible or low-friction one.
- Add a step before the SMS where it makes sense. Twilio's guide gives the example of asking users to confirm their email address before enrolling in two-factor authentication.
- Do not send texts from unauthenticated pages that do not need them, such as "text me the app link" on a marketing page; a QR code or store badge works just as well.
Restrict where messages can go
- Country restrictions. The guide recommends reviewing geographic permissions and disabling all countries you do not plan to send messages to. A business serving only the US and Canada has no reason to send codes elsewhere.
- Line-type checks. Looking up a number's line type before sending lets you send SMS only to mobile numbers, and carrier information can help block networks associated with inflated traffic.
- IP checks. The guide suggests analysing IP location and ownership and blocking proxies, Tor and cloud providers where appropriate, while acknowledging legitimate VPN users exist.
Monitor and alert
The most useful single measure is the verification conversion rate: codes entered divided by codes sent. Twilio's guide recommends internal monitors on this rate and an alert for manual review if it drops, especially in an unexpected country. Add a usage or spend alert on your SMS account so a sudden surge reaches someone the same day, not at the end of the month.
Use your provider's protections
Many SMS and verification providers have built-in fraud controls. Twilio's guide, for example, recommends enabling its SMS fraud protection feature, which blocks suspicious messages before they are sent, and disabling channels you do not use, such as voice. Check what your provider offers and whether it is switched on; these features are often off by default or need configuring.
Consider alternatives to SMS
For logins, authenticator apps and passkeys avoid per-message costs entirely. For sign-up verification, email confirmation can replace or precede SMS. Keep SMS where it genuinely helps customers, and protect it well.
A worked example
Picture a hypothetical Phoenix fitness-studio chain whose booking app sent a text code at sign-up. One weekend, the SMS bill rose sharply; logs showed thousands of codes sent to sequential numbers abroad, and almost none were entered.
The developers restricted SMS to the US and Canada, added per-number, per-IP and per-prefix limits with increasing resend delays, put an invisible bot check on the sign-up form, enabled their provider's fraud protection and set a daily spend alert. They also added a monitor on code completion rate. The attack traffic stopped reaching the provider, and a later burst was caught by the alert within an hour.
FAQ
Will rate limits annoy real customers?
Rarely, if limits are set around real behaviour. Real customers seldom request more than two or three codes.
Can I get the charges refunded?
That depends on your provider's policy. Assume you cannot, and prevent it.
Are web forms or apps more at risk?
Both. Bots can call your app's API directly, so put the protections on the server.
If your sign-up or login texts have ever produced a surprising bill, tell us how your verification works.