# agentsocks

> agentsocks is an open-source MCP server for developer tools. Lets Claude Code and Codex sessions on one machine message each other and share tasks. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** CLI, Linux, macOS
- **Repository:** https://github.com/aelethion/agentsocks
- **MCP Registry name:** io.github.Aelethion/agentsocks
- **Categories:** [developer tools](https://ai-powered.com/categories/developer-tools), [AI models and LLM tooling](https://ai-powered.com/categories/ai-and-llm)
- **Listing updated:** 2026-11-23

## About

agentsocks connects coding-agent sessions running on the same computer. From a Codex session you can say to tell api-worker that a migration is done, and the message arrives in the Claude Code session the way Claude already receives messages, through its own cross-session inbox. Nothing is typed into a terminal: it avoids tmux send-keys and fake user input, so a message from another agent is never treated as you and cannot answer a permission prompt.

Besides messages, a session can ask up to 16 others one question and collect the answers (experimental), or hand over a tracked task with an owner, state and result. Attention routing keeps a busy session from being interrupted by every note, sending FYIs as a digest. Channels, a live view called agentsocks top and an optional gateway linking your own machines over a tailnet are experimental.

It needs Node.js 22.13 or later, Claude Code 2.1.224 or later and Codex CLI 0.162 or later, with the other agents listed, such as OpenCode, Cursor and Gemini CLI, marked experimental. The README warns that it depends on non-stable internals of Claude Code and Codex, so updates can break delivery, and that it was built and tested on Linux, not yet used with real sessions on a Mac. It is not affiliated with Anthropic or OpenAI.

## Features

- **Cross-agent messaging:** Send messages between Claude Code and Codex sessions, or from a shell.
- **Tracked tasks:** Hand over a task with an owner, a state and a result.
- **Group questions:** Ask up to 16 sessions one question and get answers together (experimental).
- **Attention routing:** Digests FYIs and holds floods until a busy session finishes its turn.
- **No terminal injection:** Messages are never typed in and cannot answer permission prompts.
- **Doctor check:** agentsocks doctor verifies Node version, Codex queue and each agent's wiring.

## Good for

- Tell a Claude Code worker that a database migration finished
- Hand a task from Codex to a Claude Code session
- Ask several coding sessions the same question
- See which agent sessions are running on your machine
- Coordinate a frontend and an API session

## Install

### Claude Code: Add with the CLI (Terminal)

```sh
claude mcp add agentsocks -- npx -y agentsocks
```

Add --scope user to use it in every project, or --scope project to share it in .mcp.json.

### Claude Code: Or share it with your project (.mcp.json)

```json
{
  "mcpServers": {
    "agentsocks": {
      "command": "npx",
      "args": [
        "-y",
        "agentsocks"
      ]
    }
  }
}
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "agentsocks": {
      "command": "npx",
      "args": [
        "-y",
        "agentsocks"
      ]
    }
  }
}
```

Settings → Developer → Edit Config, then quit and reopen Claude Desktop.

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "agentsocks": {
      "command": "npx",
      "args": [
        "-y",
        "agentsocks"
      ]
    }
  }
}
```

Use .cursor/mcp.json in a project to share it with the project.

### VS Code (~/.copilot/mcp-config.json)

```json
{
  "mcpServers": {
    "agentsocks": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "agentsocks"
      ]
    }
  }
}
```

Or put the same entry in .mcp.json at your workspace root to share it.

### Codex: Add with the CLI (Terminal)

```sh
codex mcp add agentsocks -- npx -y agentsocks
```

### Codex: Or add to config.toml (~/.codex/config.toml)

```toml
[mcp_servers.agentsocks]
command = "npx"
args = ["-y", "agentsocks"]
```

### Gemini CLI and Antigravity: Gemini CLI (~/.gemini/settings.json)

```json
{
  "mcpServers": {
    "agentsocks": {
      "command": "npx",
      "args": [
        "-y",
        "agentsocks"
      ]
    }
  }
}
```

Or run: gemini mcp add -s user agentsocks npx -- -y agentsocks

### Gemini CLI and Antigravity: Antigravity (~/.gemini/config/mcp_config.json)

```json
{
  "mcpServers": {
    "agentsocks": {
      "command": "npx",
      "args": [
        "-y",
        "agentsocks"
      ]
    }
  }
}
```

Use .agents/mcp_config.json to add it to one workspace only.

### Devin Desktop (~/.config/devin/mcp_config.json)

```json
{
  "mcpServers": {
    "agentsocks": {
      "command": "npx",
      "args": [
        "-y",
        "agentsocks"
      ]
    }
  }
}
```

On Windows the file is %APPDATA%\\devin\\mcp_config.json. Use .devin/mcp_config.json to share it with a project.

### Cline (cline_mcp_settings.json)

```json
{
  "mcpServers": {
    "agentsocks": {
      "command": "npx",
      "args": [
        "-y",
        "agentsocks"
      ]
    }
  }
}
```

Open it from the MCP Servers icon → Configure → Configure MCP Servers.

### Zed (Zed settings.json)

```json
{
  "context_servers": {
    "agentsocks": {
      "command": "npx",
      "args": [
        "-y",
        "agentsocks"
      ]
    }
  }
}
```

Open it with zed: open settings file. Merge context_servers into the settings you already have.

### JetBrains AI Assistant and Junie: AI Assistant (Settings → Tools → AI Assistant → Model Context Protocol (MCP) → Add)

```json
{
  "mcpServers": {
    "agentsocks": {
      "command": "npx",
      "args": [
        "-y",
        "agentsocks"
      ]
    }
  }
}
```

### JetBrains AI Assistant and Junie: Junie (~/.junie/mcp/mcp.json)

```json
{
  "mcpServers": {
    "agentsocks": {
      "command": "npx",
      "args": [
        "-y",
        "agentsocks"
      ]
    }
  }
}
```

Use .junie/mcp/mcp.json to share it with a project.

### Kiro (~/.kiro/settings/mcp.json)

```json
{
  "mcpServers": {
    "agentsocks": {
      "command": "npx",
      "args": [
        "-y",
        "agentsocks"
      ]
    }
  }
}
```

Use .kiro/settings/mcp.json to add it to one workspace only.

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "agentsocks": {
      "command": "npx",
      "args": [
        "-y",
        "agentsocks"
      ]
    }
  }
}
```

## FAQ

### What does agentsocks require?

Node.js 22.13 or later, Claude Code 2.1.224 or later and Codex CLI 0.162 or later.

### Does agentsocks work across machines?

Only on one machine by default; an experimental gateway can link your own machines over a tailnet.

### Which agents are fully supported?

Claude Code and Codex CLI; others such as OpenCode, Cursor and Gemini CLI are experimental and Aider is unsupported.

### Is agentsocks safe for installed configs?

agentsocks install backs up every file it edits and offers a --dry-run.

### Is agentsocks free?

Yes. agentsocks is open source, so you can use and self-host it for free.

### How do I add agentsocks to Claude Code?

Run this command in your terminal: claude mcp add agentsocks -- npx -y agentsocks

### What are the best alternatives to agentsocks?

The closest alternatives to agentsocks are REA, Context7, Chrome DevTools MCP, Codebase Memory and GitHub.

## Where this comes from

- Description: written from the project's README.
- Install steps: from the official MCP Registry entry.

## Alternatives

- [REA](https://ai-powered.com/mcp/rea): REA is an open-source MCP server for developer tools.
- [Context7](https://ai-powered.com/mcp/context7): Context7 is a freemium MCP server for developer tools.
- [Chrome DevTools MCP](https://ai-powered.com/mcp/chrome-devtools-mcp-2): Chrome DevTools MCP is an open-source MCP server for browser automation.
- [Codebase Memory](https://ai-powered.com/mcp/codebase-memory): Codebase Memory is an open-source MCP server for knowledge and memory.
- [GitHub](https://ai-powered.com/mcp/github): GitHub is an open-source MCP server for developer tools.
- [Serena MCP: the IDE for your agent](https://ai-powered.com/mcp/serena-mcp-the-ide-for-your-agent): Serena MCP: the IDE for your agent is an open-source MCP server for developer tools.
- [XERJ](https://ai-powered.com/mcp/xerj): XERJ is an open-source MCP server for knowledge and memory.
- [awesome-mcp-servers](https://ai-powered.com/mcp/awesome-mcp-servers-2): awesome-mcp-servers is an open-source MCP server for developer tools.

---
Source: https://ai-powered.com/mcp/agentsocks
