iMessage & SMS Integration Guide
Want to text your AI agent like a friend? OpenClaw connects to both iMessage and SMS. Here's how each one works, what they cost, and which to pick for your setup.
Why Text Your AI Agent?
Most people already check their messages 100+ times a day. Connecting your OpenClaw agent to iMessage or SMS means your AI lives where you already pay attention. No new app, no separate notifications, just a normal conversation thread.
Whether you want morning briefs, alerts, or quick research without opening anything, texting is the lowest-friction interface that exists. And OpenClaw makes it work both ways.
iMessage vs SMS: Which Should You Pick?
OpenClaw supports both, but they're very different. Here's the honest comparison:
| Feature | iMessage | SMS (Twilio) |
|---|---|---|
| Cost | Free | ~$0.0075 per message |
| Phone number rental | Free (uses your Apple ID) | ~$1.15/month (US) |
| Works on | Apple devices only | Every phone worldwide |
| Needs a Mac running | Yes | No |
| Rich media | Images, videos, tapbacks, effects | Text only (MMS extra) |
| Group chats | Yes, full support | Yes, but limited |
| Read receipts | Yes | No |
| Encryption | End-to-end (Apple) | Plain text |
| Setup difficulty | Medium (needs Mac) | Easy (Twilio account) |
Short answer: If you and your contacts are all on Apple devices, use iMessage. It's free and feature-rich. If you need anyone with a phone to be able to text your agent, use SMS.
Setting Up iMessage with OpenClaw
OpenClaw uses a native macOS integration called imsg. It talks to your Messages app directly via JSON-RPC. No separate daemon, no port to open. Just a Mac signed into your Apple ID.
You'll need:
- ๐ฅ๏ธ A Mac that stays on (Mac Mini works great)
- ๐ macOS Messages app signed in with your Apple ID
- ๐ Full disk access permission for your Gateway process
- โ๏ธ
imsgCLI installed and accessible
This is the simplest case. Add this to your openclaw.json:
{
"channels": {
"imessage": {
"enabled": true,
"cliPath": "/usr/local/bin/imsg",
"dmPolicy": "pairing"
}
}
}Restart the Gateway. Send a message to yourself from any iPhone or another Mac to pair, and you're done.
You still need a Mac somewhere. SSH into it from your Gateway:
{
"channels": {
"imessage": {
"enabled": true,
"cliPath": "ssh user@mac.local /usr/local/bin/imsg",
"dmPolicy": "pairing"
}
}
}The Gateway runs imsg on the Mac through SSH. Slightly slower, but works fine. See OpenClaw on iMessage for the full guide.
Skip the Mac entirely?
Ampere.sh managed hosting handles iMessage on a hosted Mac so you don't need one running at home. Try it free for 7 days.
Setting Up SMS with Twilio
SMS uses Twilio under the hood. You point Twilio at your Gateway via webhook, and replies go back through Twilio's API. Works anywhere your Gateway has a public URL.
You'll need:
- ๐ A Twilio account with an SMS-capable phone number
- ๐ Twilio Account SID and Auth Token
- ๐ A public HTTPS URL that reaches your Gateway
- ๐ณ ~$5-15/month budget for messages and number rental
Sign up at twilio.com, buy an SMS-capable number, and save:
- Account SID (starts with
AC...) - Auth Token
- Phone number (e.g.
+15551234567)
Save this as sms.patch.json5 with your actual values:
{
channels: {
sms: {
enabled: true,
accountSid: "ACxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
authToken: "twilio-auth-token",
fromNumber: "+15551234567",
publicWebhookUrl: "https://gateway.example.com/webhooks/sms",
dmPolicy: "pairing"
}
}
}Apply it:
openclaw config patch --file ./sms.patch.json5 --dry-run
openclaw config patch --file ./sms.patch.json5In Twilio's phone number settings, find Messaging โ A message comes in. Set it to:
https://gateway.example.com/webhooks/smsUse HTTP POST. If you're testing locally, expose the webhook with Tailscale Funnel or similar.
Text your Twilio number from your phone. OpenClaw triggers pairing (DM by default). Approve the sender, then start chatting normally.
What People Actually Use This For
Texting your agent unlocks some surprisingly useful workflows:
- Morning brief texted at 7 AM (calendar + weather + emails)
- Quick research without opening a browser
- Reminders that show up as normal messages
- Photo OCR - send a receipt, get expenses logged
- Crypto alerts when prices hit your targets
- SMS support line that drafts replies for human approval
- Field worker check-ins via SMS
- Customer appointment confirmations
- Lead capture and qualification by text
- Two-way SMS surveys with AI follow-up
How Much Does This Actually Cost?
Honest numbers for personal use, sending 10-50 messages per day:
| Setup | Monthly Cost | Notes |
|---|---|---|
| iMessage on your own Mac | $0 + electricity | Mac stays on 24/7 |
| iMessage on hosted Mac | $25-50/mo | See Mac hosting guide |
| SMS personal use (light) | ~$5/mo | ~10 msgs/day + number |
| SMS personal use (heavy) | ~$15/mo | ~50 msgs/day + number |
| SMS business (1000s of msgs) | $50-500/mo | Scales with usage |
| โญ Ampere.sh managed | $39/mo flat | iMessage + Mac + setup all included |
Buying a Mac Mini ($600+) and running it 24/7 sounds cheap until you add up the electricity, replacement after 4-5 years, and the hours you spend on setup and maintenance.
Ampere.sh costs $39/mo flat and gets you iMessage on a managed Mac, no purchase, no setup, no babysitting. For most people, this works out cheaper in the first year and way less hassle.
Don't forget AI model costs on top of these. See our cost optimization guide to keep them low.
Common Issues and How to Fix Them
- โ ๏ธ iMessage not receiving messages - Check your Mac is signed in to iMessage, Messages app is running, and full disk access is granted
- ๐ต SMS webhook errors in Twilio - Make sure your public URL actually reaches the Gateway. Test with
curlfirst - ๐ iMessage sends but doesn't receive - Could be macOS sleeping. Disable sleep on your Mac Mini
- ๐ฐ Twilio bill is higher than expected - Check your dmPolicy. "open" lets anyone text you - use "pairing" for personal use
- ๐ Group iMessage not working - Group support needs the private API probe to succeed. Run
imsg launchonce manually
For more, see bot not responding and gateway won't start troubleshooting guides.
Run Both Channels Together
You can run iMessage and SMS at the same time. OpenClaw routes each conversation independently. Your iPhone contacts hit iMessage for free, Android friends use SMS through Twilio, everyone gets the same agent.
This is actually the smart setup for businesses. Save money on Apple users, still serve everyone else. Configure both channels in your config and you're done.
The Easiest Way to Get Started
Look, setting up either of these involves real infrastructure - a Mac running 24/7 or a Twilio account with a webhook. If you just want it to work without thinking about it, Ampere.sh handles everything including a hosted Mac for iMessage.
No Mac purchase, no SSH config, no public URL, no Twilio webhook headaches. Sign up, deploy, start texting your agent. First 7 days are free.
Quick Reference
| Action | Command |
|---|---|
| Enable iMessage channel | openclaw config set channels.imessage.enabled true |
| Test iMessage CLI | imsg --help |
| Apply SMS patch config | openclaw config patch --file sms.patch.json5 |
| Check active channels | openclaw gateway status |
| Restart Gateway | openclaw gateway restart |
Frequently Asked Questions
Can OpenClaw send and receive iMessage and SMS?
What's the difference between iMessage and SMS in OpenClaw?
Do I need a Mac to use OpenClaw with iMessage?
How much does SMS cost with OpenClaw?
Which is better - iMessage or SMS for an AI agent?
Can I use both iMessage and SMS at the same time?
Is iMessage in OpenClaw the same as BlueBubbles?
Can my agent reply to group iMessage chats?
Also Read
Text your AI agent today
OpenClaw works with iMessage and SMS so your AI lives where you already text. Skip the setup and try managed hosting on Ampere.sh - 7-day free trial.
Start Free Trial

