agent-bridge
Let your AI agents on different machines talk to each other.
agent-bridge connects running AI agent harness sessions across your own computers using SSH and local inboxes. Send a task to the agent already sitting on another laptop, ask your always-on desktop to run a diagnostic, or let different harnesses coordinate without copy-pasting between chats.

Website | GitHub
Why use it?
- Agent-to-agent messages — push work to a live agent on another machine and get a reply in context.
- No cloud relay — peer-to-peer over SSH; config, keys, inboxes, and logs live on your machines.
- Works across harnesses — Claude Code and OpenClaw are tested end-to-end, with the same bridge tools shared through MCP.
- Remote diagnostics when needed — run plain shell commands on a paired machine for status checks, logs, tests, and one-off troubleshooting.
- Explicit routing — target Claude Code personas, OpenClaw accounts, or other named sessions directly instead of relying on fuzzy defaults.
- Shared context — a fleet-wide learnings store every agent on every machine can search and contribute to, replicated peer-to-peer over the same SSH transport.
What works today
- Claude Code: tested end-to-end with a unified MCP/channel plugin.
- OpenClaw: tested end-to-end with a native channel plugin plus the shared MCP tools.
- Codex (4.10.0+): first-class both ways — bound tasks receive pushed turns via the background codex-channel service (the task itself never polls; the service scans the inbox and wakes the exact persisted thread through the App Server), and any Codex task sends via the bridge MCP tools or
agent-bridge codex send.
- Other MCP hosts (Gemini CLI, Aider): scaffolded for manual receive/polling flows; empirical reports and PRs are welcome.
Quick start
Paste this into your Claude Code or OpenClaw session on each computer you want to bridge:
Read the README at https://github.com/EthanSK/agent-bridge and follow the setup instructions
for this computer. Install agent-bridge, run the setup command, and install the appropriate
channel plugin (Claude Code's `mcp-server/` plugin OR OpenClaw's `openclaw-channel/`,
matching whichever harness you're running). Do everything automatically — don't ask me
questions.
Prereqs (once per machine):
- macOS: System Settings > General > Sharing > toggle Remote Login ON > click (i) > set "Allow access for" to All users. Optionally toggle "Allow full disk access for remote users".
- Linux:
sudo systemctl enable --now sshd
- Windows 10/11: OpenSSH Server is an optional feature, not on by default. See the Windows setup section below for the consolidated install + firewall + admin-key script.
Then photograph the pairing screen on one machine and send it to the Claude Code or OpenClaw session on the other. That's the pair step; the agents handle the rest. Either harness can pair with either harness — Claude Code↔OpenClaw, OpenClaw↔OpenClaw, etc.
Setup notes
agent-bridge is designed for people to use, but first-time setup still depends on SSH, local agent plugins, and the agent harness you run. If something does not work first try:
- Ask your local AI agent (Claude Code, OpenClaw, etc.) to inspect the setup and logs for your machine. The bridge writes structured NDJSON logs at
~/.agent-bridge/logs/agent-bridge.log, and event names are documented in docs/operations.md.
- Open an issue at https://github.com/EthanSK/agent-bridge/issues with the failure mode and your environment details.
- PRs are welcome — especially small fixes for cross-platform paths, alternate install locations, and harness-specific quirks.
For agents setting this up
If you are an AI agent onboarding agent-bridge onto a new machine, read the setup docs before sending your first bridge message. The three most important docs are:
docs/named-target-routing.md — when the user names a specific target alias, match that alias literally.
docs/relay-to-user.md — inbound bridge messages should be relayed to the user with a short summary plus source/destination endpoint versions.
docs/operations.md — stale runtime recovery, plugin reloads, and the practical checks for "I rebuilt but nothing changed."
Other docs in docs/ cover auto-update, channel-plugin history, lifecycle notes, and investigation reports.
What is agent-bridge?