OpenClaw's gateway is the central hub that connects your AI agent to the world — messaging channels, devices, tools, and services. But the real magic happens when you pair devices (called "nodes") to your gateway.
Once paired, your agent can snap photos from your phone's camera, check your laptop's screen, get your GPS location, run commands on remote machines, and send push notifications — all through natural conversation. This guide covers everything you need to know about OpenClaw gateway connect and pairing.
What Is the OpenClaw Gateway?
The OpenClaw gateway is the core daemon that powers your AI agent. Think of it as the brain's connection to the outside world. It handles:
- Messaging channels — Discord, Telegram, WhatsApp, Signal, Slack, iMessage
- Device pairing — phones, laptops, Raspberry Pis, servers
- Tool execution — running commands, browsing the web, managing files
- Session management — main conversations, sub-agents, cron jobs
- Memory persistence — your agent's long-term memory across restarts
The gateway runs on your server (or on Ampere.sh if you prefer managed hosting) and stays connected 24/7. Every interaction — whether from a Discord message, a scheduled task, or a paired device — flows through the gateway.
Setting Up the OpenClaw Gateway
Installation
If you're self-hosting, install OpenClaw with a single command:
$ npm install -g openclawThen initialize your workspace:
$ openclaw init
✓ Created ~/.openclaw/workspace
✓ Generated openclaw.yaml
✓ Created SOUL.md, USER.md, AGENTS.mdStarting the Gateway
Launch the gateway daemon:
$ openclaw gateway start
✓ Gateway started (PID 12345)
✓ Listening on https://your-gateway-urlCheck the status at any time:
$ openclaw gateway status
Gateway: running (uptime 2d 14h)
Channels: discord ✓, telegram ✓
Nodes: 2 paired, 1 onlineUsing Ampere? If you're on Ampere.sh, the gateway is already running for you. Skip straight to the device pairing section — everything is pre-configured and ready to connect.
Gateway Configuration
The gateway is configured through openclaw.yaml. Here's a breakdown of the key sections relevant to connecting and pairing:
# openclaw.yaml - Gateway configuration
model: anthropic/claude-sonnet-4-20250514
channels:
discord:
token: "YOUR_DISCORD_BOT_TOKEN"
telegram:
token: "YOUR_TELEGRAM_BOT_TOKEN"
nodes:
enabled: true
autoApprove: false # require manual approval
heartbeat:
enabled: true
intervalMs: 1800000 # 30 minutesThe nodes section controls device pairing behavior. With autoApprove: false, every new device must be manually approved before it can connect — a critical security feature.
Device Pairing: Connecting Nodes to Your Gateway
In OpenClaw, a node is any device paired to your gateway. Nodes give your AI agent physical presence — the ability to see through cameras, know your location, run commands on your machines, and send you notifications.
What Can Paired Nodes Do?
Camera Access
Snap photos from front or back cameras on your phone. "Take a photo of what's in front of me."
Location Tracking
Get your GPS coordinates on demand. "Where am I right now?" or "How far am I from home?"
Screen Capture
Capture what's on your screen. Great for debugging or showing your agent what you're looking at.
Push Notifications
Your agent sends notifications directly to your phone. Urgent alerts, reminders, or just friendly check-ins.
Remote Commands
Run shell commands on paired machines. Deploy code, check server health, or manage files remotely.
Browser Control
Control a browser instance on the paired device for automation, testing, or research tasks.
How Pairing Works
The pairing process uses a secure handshake between the node (your device) and the gateway (your server). Here's the flow:
- Node initiates — the device sends a pairing request to your gateway URL
- Gateway queues — the request appears as "pending" for approval
- You approve — either through the dashboard, CLI, or by telling your agent to approve it
- Connection established — the node maintains a persistent connection to the gateway
- Capabilities shared — the node reports what it can do (camera, location, shell, etc.)
Security Note: Always review pairing requests carefully. A paired node has significant access to interact with your agent. Only approve devices you own and trust. The autoApprove: false setting is recommended for production use.
Pairing Your Phone (iOS & Android)
Your phone is the most powerful node you can pair. It gives your agent access to cameras, GPS, push notifications, and more.
Step 1: Install the OpenClaw Node App
Download the OpenClaw Node app for your device. Check the OpenClaw documentation for the latest download links and supported platforms. The app runs in the background and maintains a persistent connection to your gateway.
Step 2: Enter Your Gateway URL
Open the app and enter your gateway URL. If you're on Ampere, this is your *.ampere.sh endpoint. For self-hosted setups, it's your server's domain or IP.
# Example gateway URLs
Ampere: https://your-agent.ampere.sh
Self-hosted: https://openclaw.yourdomain.comStep 3: Approve the Pairing Request
Once the app sends the pairing request, approve it from your gateway. You have several options:
# Option 1: CLI
$ openclaw nodes pending
1 pending request: "John's iPhone" (ios, model: iPhone 15 Pro)
$ openclaw nodes approve --id johns-iphone
✓ Node paired successfully
# Option 2: Tell your agent in chat
"Hey, approve the pending pairing request from my iPhone"Step 4: Grant Permissions
The app will ask for permissions based on what capabilities you want to enable:
- Camera — for photo/video capture on demand
- Location — for GPS tracking when requested
- Notifications — for push alerts from your agent
- Background App Refresh — to stay connected when the app isn't active
You can always adjust permissions later. The agent will only use capabilities the node reports as available.
Pairing a Laptop or Desktop
Pair your Mac, Windows, or Linux machine to give your agent access to screen capture, shell commands, and browser control.
# Install the node agent on your laptop
$ npm install -g @openclaw/node-agent
# Connect to your gateway
$ openclaw-node connect https://your-gateway-url
Pairing request sent. Waiting for approval...
✓ Paired as "MacBook Pro (work)"
✓ Capabilities: shell, screen, browser, clipboardOnce paired, your agent can execute commands on your laptop, take screenshots, and even control a headless browser — all through chat.
Pairing a Raspberry Pi or Remote Server
IoT devices and remote servers are perfect nodes for monitoring, automation, and home control.
# On your Raspberry Pi
$ npm install -g @openclaw/node-agent
$ openclaw-node connect https://your-gateway-url --name "home-pi"
# With a camera module attached
✓ Paired as "home-pi"
✓ Capabilities: shell, cameraUse cases for server nodes:
- Home monitoring — snap Pi camera photos on demand or on schedule
- Server management — check disk space, restart services, deploy code
- IoT control — toggle smart devices through shell scripts
- Network monitoring — ping hosts, check connectivity, run diagnostics
Managing Paired Nodes
Once devices are paired, you can manage them through the CLI, dashboard, or by chatting with your agent.
View Connected Nodes
$ openclaw nodes status
┌──────────────────┬──────────┬────────────┬──────────────────────┐
│ Name │ Status │ Platform │ Capabilities │
├──────────────────┼──────────┼────────────┼──────────────────────┤
│ John's iPhone │ online │ ios │ camera, location, │
│ │ │ │ notify │
│ MacBook Pro │ online │ macos │ shell, screen, │
│ │ │ │ browser, clipboard │
│ home-pi │ offline │ linux │ shell, camera │
└──────────────────┴──────────┴────────────┴──────────────────────┘Interacting Through Chat
The best part about paired nodes? You interact with them naturally through your agent:
You: "Take a photo from my phone's back camera"
Agent: Here's the photo from your iPhone's back camera.
You: "What's the disk space on home-pi?"
Agent: home-pi has 12.4 GB free out of 32 GB (61% used).
You: "Send me a notification if the temperature sensor reads above 30°C"
Agent: Got it. I'll monitor the sensor and ping your phone if it goes above 30°C.Troubleshooting Gateway Connect & Pairing
Running into issues? Here are the most common problems and their fixes:
"Pairing Required" Error
If you see "pairing required" when trying to use node features, it means no device is paired to your gateway. Follow the pairing steps above to connect at least one device.
"Connect Failed" or Timeout
- Check your gateway URL — make sure it's accessible from the device's network
- Firewall rules — ensure the gateway port is open (default: 443 for HTTPS)
- SSL certificates — nodes require a valid HTTPS connection. Use Let's Encrypt or a tunnel service
- Gateway running? — verify with
openclaw gateway status
Node Shows "Offline"
- Phone — check that background app refresh is enabled and the app hasn't been killed by the OS
- Laptop — the node agent may have stopped. Restart it with
openclaw-node connect - Server — check if the process is running:
systemctl status openclaw-node
Permissions Not Working
If your agent can't access the camera or location on a paired phone:
- Open the OpenClaw Node app and check granted permissions
- On iOS: Settings → OpenClaw Node → enable Camera/Location
- On Android: Settings → Apps → OpenClaw Node → Permissions
Security Best Practices for Gateway & Pairing
Pairing devices to your AI agent is powerful — which means security matters. Follow these best practices:
- Always use manual approval — set
autoApprove: falsein your config - Review pending requests — only approve devices you recognize
- Use HTTPS — never expose your gateway over plain HTTP
- Rotate credentials — if a device is lost, unpair it immediately from the gateway
- Limit capabilities — only grant permissions each node actually needs
- Monitor activity — check node usage logs periodically
- Keep updated — run the latest OpenClaw version for security patches
Pro Tip: If you're using Ampere.sh, the gateway connection is already secured with TLS, automatic certificate management, and DDoS protection. You get enterprise-grade security without the configuration overhead.
Advanced Gateway Features
Multi-Node Orchestration
With multiple nodes paired, your agent can coordinate across devices. For example:
- "Take a photo from the home-pi camera and send it to my phone as a notification"
- "Run the deploy script on my MacBook and show me the result on Telegram"
- "Check if I'm home (phone GPS) and if so, run the evening lighting script on the Pi"
Gateway Restart & Config Updates
You can update your gateway configuration without losing paired nodes:
$ openclaw gateway restart
✓ Gateway restarted. All nodes will reconnect automatically.Paired nodes automatically reconnect after a gateway restart. No need to re-pair — the trust relationship persists.
Combining Nodes with Cron Jobs
Schedule automated tasks that use your paired nodes:
- Take a security photo from home-pi every hour
- Check server health on all paired machines every 30 minutes
- Send a morning briefing notification to your phone at 8 AM
Frequently Asked Questions
How many devices can I pair to one gateway?
Do paired devices need to be on the same network?
What happens if my phone loses connection?
Can I unpair a device remotely?
Is the connection between nodes and gateway encrypted?
Does pairing drain my phone's battery?
Can multiple users pair to the same gateway?
Your Agent, Everywhere
Gateway connect and device pairing transform OpenClaw from a text-based chatbot into a truly ambient AI agent. Your agent isn't trapped in a chat window — it can see through your cameras, know where you are, control your machines, and proactively reach out when something needs your attention.
The setup takes minutes: install OpenClaw, start the gateway, pair your devices, and you're live. Your agent grows more useful with every node you connect.
Ready to connect your world to your AI agent? Ampere.sh makes it effortless — managed gateway, instant pairing, zero infrastructure to maintain.
Ready to connect your devices?
Get a managed OpenClaw gateway with instant device pairing on Ampere.
Get Started with Ampere →