A new peer-to-peer terminal chat tool lets Claude Code users connect directly without servers, accounts, or costs.
Claude Code's New Terminal Chat: Connect with Other Devs via P2P
What It Does — Terminal-Based Community Chat
claude-p2p-chat is a terminal application that creates a distributed chat network specifically for Claude Code users. Unlike Discord, Slack, or web-based communities, this runs entirely in your terminal using Hyperswarm DHT for peer discovery — no servers, no signups, and no costs.
When you run it, you immediately join #lobby where you can see other online Claude Code developers. The interface shows channels on the left, messages in the center, and online users on the right — all in a beautifully formatted TUI.
Setup — Two Commands to Get Started
Run it once without installation:
npx claude-p2p-chat
Or install it globally for regular use:
npm install -g claude-p2p-chat
claude-p2p-chat
Set your username with --name flag or change it in-chat with /nick yourname.
When To Use It — Real-Time Collaboration Without Context Switching
This tool shines when you're already in your terminal workflow with Claude Code and want to:
- Ask quick questions about Claude Code features or MCP servers
- Share discoveries about new prompting techniques or workflows
- Find collaborators for open-source Claude Code projects
- Get unstuck without leaving your development environment
Create custom channels for specific topics:
/join #mcp-servers
/join #claude-md-tips
/join #agent-development
Send direct messages to specific users:
/dm username "Hey, saw your MCP server — how did you handle authentication?"
Integrate with Claude Code as a Skill
Make it accessible directly from Claude Code by creating a skill:
- Create
~/.claude/skills/chat/SKILL.md:
---
name: chat
description: "Open P2P Chat"
---
Run via Bash: `npx claude-p2p-chat`
- Now you can launch it with:
/chat
How It Works — Truly Distributed
The chat uses Hyperswarm DHT (distributed hash table) for peer discovery. Each channel name is hashed to create a unique topic identifier. Peers find each other through the DHT network, establish encrypted WebRTC connections, and messages flow directly between them.
You ←──encrypted──→ Peer A
↕ ↕
Peer B ←──────────→ Peer C
Chat history is stored locally in ~/.claude-chat/history/ — there's no central server storing messages. If you weren't online when a message was sent, you won't see it (similar to IRC).
Keyboard Shortcuts for Power Users
-
Tab— Cycle between channels, users, and input -
Esc— Refocus the input box - Mouse wheel — Scroll in the message area
-
Ctrl+C— Quit (when not typing)
Requirements
- Node.js 18+
- Terminal that supports Unicode and 256 colors
- Works on Linux, macOS, and Windows (WSL)
This follows the growing trend of terminal-first tools in the Claude Code ecosystem, where developers want to stay in their workflow without switching to browser-based applications.
Originally published on gentic.news
Top comments (0)