Send WhatsApp messages in Python,
in a few lines.
A pip install, an API key, and three lines of Python are all it takes to send a WhatsApp message. The SDK handles authentication, media and webhooks for you - from your regular WhatsApp account, unlimited, without setting up Meta's official API.
The context
How do you send a WhatsApp message in Python?
The Python SDK is a package you install from PyPI with pip to send WhatsApp messages from any script, backend or notebook, without writing a single HTTP request by hand.
In Python, sending a WhatsApp often comes down to a POST to a REST endpoint. You could do it with requests: build the URL, set the authentication header, serialize the JSON, check the return code, handle network errors. It works, but you rewrite the same plumbing every time - and you lose your editor's autocompletion and typing.
The Python SDK does that work for you. You run `pip install unlimited-messaging`, you instantiate a `Client` with your API key, then you call `client.message.send(recipient=..., text=...)`. The SDK takes care of authentication, serialization, typed errors and retries. Media and webhooks follow the same logic: a Python method, not an HTTP schema to memorize.
Above all, this SDK doesn't force you to go through Meta's official WhatsApp Business API. No business account to verify, no templates to get approved, no per-conversation billing: messages go out from your regular WhatsApp account, unlimited, at a fixed price. It's the ideal tool for scripts, Django or FastAPI backends and data notebooks.
Comparison
Meta's official API in Python vs Unlimited Messaging Python SDK
The same goal - sending a WhatsApp message from Python - via two very different paths. On the left, Meta's official WhatsApp Business API called over raw HTTP with requests. On the right, Unlimited Messaging's Python SDK. Line by line, what each approach requires.
| Meta's official API in Pythonraw HTTP with requests | Unlimited Messaging Python SDKpip install, typed client | |
|---|---|---|
| Installation | requests + HTTP code to write | pip install unlimited-messaging |
| Business account required | Verified Meta Business account | Your regular WhatsApp account |
| Templates to approve | Meta approval required | None, free text |
| Lines to send | ~20 (URL, headers, JSON, errors) | 3 lines of Python |
| Media | Upload + media_id in two steps | One URL passed to the method |
| Webhooks | To receive and verify yourself | Typed JSON payloads, ready to use |
| Pricing | Per conversation, variable | Fixed monthly price |
| Unlimited | No - billed per message | Yes, unlimited messages |
Our approach
A Python SDK that fits in three lines
We keep the rigor of a real API - typed client, explicit errors, webhooks - and remove all the Meta friction. You write Python, not HTTP plumbing.
pip install, then you send
One pip command and the client is available. Instantiate `UnlimitedMessagingApi(token=...)`, call `client.message.send()`, your WhatsApp message goes out. No Meta SDK to wire up, no business onboarding.
Typed methods, no HTTP
The SDK exposes Python methods with autocompletion and typed errors. You no longer build URLs or headers: the client handles authentication, serialization and retries.
Media and webhooks included
Send images, PDFs and videos via a simple URL. Receive delivered / read / reply statuses as JSON webhooks, without verifying anything by hand.
Unlimited, your regular account
Messages go out from your usual WhatsApp account, unlimited, at a fixed price. No templates to approve, no per-conversation billing.
- Lines to send a WhatsApp
- 3Lines to send a WhatsApp
- pip command to install
- 1pip command to install
- Supported Python versions
- 3.8+Supported Python versions
- From key to first message
- 5 minFrom key to first message
How it works
Send a WhatsApp in Python in three steps
- 1
Install the package
Run `pip install unlimited-messaging` in your project, your venv or your notebook. The client is ready to import.
- 2
Authenticate with an API key
Generate a key in your dashboard (Settings → API Keys), then pass it to the client: `UnlimitedMessagingApi(token="um_live_…")`.
- 3
Call client.message.send()
Specify the recipient and the text. For media, add a URL; for tracking, plug in your webhooks. That's it.
FAQ
Questions about the Python WhatsApp SDK
Sources
Sources & references
To check the information in this article for yourself:

Written by
Ilian · Senior Software Engineer
A senior software engineer, he founds and runs several tech companies. He builds products around messaging APIs, automation and AI integration, and shares here what he learns while building.
Ready to send WhatsApp messages from Python?
Create your account, generate an API key, run `pip install unlimited-messaging` and send your first message today.
Get my API key