ASADULELAHBOOK A CALL →

Home / Learn

Learn with Asadulelah · Lesson 6

How do I send automated WhatsApp messages without getting my number banned?

By Asadulelah, a Kerala-based builder of custom software and AI systems for businesses. I build by directing a fleet of AI agents, and this is how I actually do it.

WHO THIS IS FORBusiness owners and builders sending reminders, follow-ups or updates on WhatsApp through automation, especially through a self-hosted gateway rather than Meta's paid API.

WHAT YOU'LL HAVE AT THE ENDA sender that paces itself like a person, a warmup routine for new numbers, the signals that mean slow down, and a human handover when someone replies.

Send slowly, randomly and from a warmed number: cap each number at about 50 messages an hour and 200 a day, wait a random 15 to 30 seconds between sends, and stop automation in any chat where a human replied. Numbers get banned for looking like machines (a brand-new number, identical text, a perfect rhythm, hundreds of sends in minutes), not for automation itself.

First, the honest part. Meta's official WhatsApp Business API is the safest route and is built for volume. Unofficial gateways that drive WhatsApp Web carry real ban risk and are against WhatsApp's terms for bulk use. Where the official route was too costly for the job, I built on a self-hosted gateway, and every rule below exists because that route forgives nothing.

Where these rules come from

They aren't from a blog. They come from my own fully automated outreach system (on LinkedIn, which is just as strict), which has never been restricted, while someone I know running similar activity was. When I wrote them down I told my assistant not to just take my wording: "Actually, you have the idea from the existing project: how I actually do it to not get banned." So the doctrine was pulled from the code that already worked.

The steps

1. Pace on your side, never trust the caller

The most dangerous thing I've found in a real system was a bulk sender that paused 0.3 seconds between messages. On Meta's paid API that's fine. On an unofficial gateway it's a ban inside an hour. My own limiter waits 15 to 30 seconds, 50 to 100 times slower. The fix is architectural: whatever calls your gateway gets an instant "queued" answer, and your own worker drains the queue at your pace. Even a 5.5-second gap is far too fast for a bulk run.

2. Cap every number, on rolling windows

HOURLY_CAP, DAILY_CAP = 50, 200          # per number, rolling, not calendar hours

def send(msg):
    with send_lock:                       # one send at a time, no concurrency
        number = next_number_under_caps() # rotate; failover if one is unhealthy
        sleep(random.uniform(15, 30))     # never a fixed rhythm
        number.send(msg)
        save_counters(".limiter_data.json")  # counters survive a restart

Rolling windows matter because calendar buckets let you send 50 at 10:59 and 50 more at 11:00. Saving counters to disk matters because a crash loop that resets counters on every restart turns into a blast.

3. Randomise the rhythm

"A metronome is the easiest possible thing to detect." Real people don't send a message every 20.0 seconds. Random gaps, sends only in the recipient's daytime (I use 9 am to 9 pm in their timezone), and big runs spread across a couple of days.

4. Get capacity from more numbers, not a faster rate

When you need more volume, add numbers and rotate between them with automatic failover. Never raise the rate on one number. And never connect your main business number to automation: if anything goes wrong, you lose the number your customers know.

5. Warm a new number before it sends anything in bulk

"A number whose first-ever action is a 200-message blast is the single most detectable pattern there is." A new number gets a profile photo and real two-way chats for several days before it sends a single automated message, then starts small.

6. Vary the words, never the facts

Two hundred identical messages in five minutes is a fingerprint. Rotate phrasings, greetings, sign-offs and line breaks. But never vary the facts: amounts, dates, account details. In my code an assertion checks that every variant still carries exactly the same facts before it can be sent.

7. Watch the stop signals

Platforms degrade you quietly before they restrict you. Back off when you see: more failures or timeouts on a number that was healthy, messages accepted but never delivered, falling read receipts, more frequent demands to re-scan the QR code, slower acknowledgements. My gateway also pauses a number for 24 hours the moment it reports a restriction.

8. Hand over to a human the moment someone replies

"A reply resets everything." When a person answers, automation stops in that chat, and the reply goes to a human. In my setup, a watcher reads new replies every two minutes, writes a one-line summary and a draft answer, and posts it for review. It never sends on its own. Never send automation into a thread where a human replied in the last 24 hours.

How the gateway is built

A self-hosted open-source gateway (with its own Postgres and Redis) runs real headless Chrome sessions of WhatsApp Web, which I picked over lighter libraries because it looks like a real browser. A small service of mine sits in front: it requires a token (unauthenticated calls get a 401), deduplicates sends with a unique index in the database, normalises every phone number to one format, and starts in dry-run mode by default. In a live test the gaps between real sends were 26.0 and 23.5 seconds.

Mistakes I made

What I'd do next

If you're sending under a few dozen messages a day to people who expect them, the official API or WhatsApp Business app is enough; don't build a gateway. If you need automation, start with one warmed spare number, the caps above, dry-run on, and a human reading every reply. Add numbers only when the first one has run clean for weeks.