Loop CLI Orchestrates Claude Code and Codex for Hands-Off Agent Teams
A new open-source tool called loop is changing how developers use Claude Code for complex, multi-step tasks. Instead of manually prompting Claude Code for each step, Loop runs Claude Code and Codex in a persistent, orchestrated loop where one agent works and the other reviews.
What Loop Does
Loop is a dead-simple Bun CLI that creates a persistent tmux session with Claude Code and Codex running side-by-side. The agents communicate through the Codex App Server and Claude Code Channels, working together on a shared PLAN.md file. They iterate until both agree the task is complete, then the main worker creates a draft pull request automatically.
This creates a "meta agent loop" where coding agents become long-running collaborators. As the README states: "Stop baby sitting your agents: let them iterate on tasks with clear proof requirements until they are done."
How To Use It
Installation is straightforward:
curl -fsSL https://raw.githubusercontent.com/axeldelafosse/loop/main/install.sh | bash
This installs loop, claude-loop, and codex-loop to ~/.local/bin on macOS and Linux.
Basic usage:
# Start a task with specific requirements
loop --prompt "Implement user authentication" --proof "Write unit tests for all endpoints"
# Start paired interactive tmux workspace
loop
# Open dashboard of running instances
loop dashboard
Loop runs in paired mode by default: one agent does the work while the other stays available for review and support. It keeps both Claude Code and Codex sessions persistent across iterations and bridges messages between them.
Critical Safety Warning
The Loop documentation includes an important warning in all caps: "you SHOULD run this inside a VM. It is NOT safe to run this on your host machine. The agents are running in YOLO mode!"
The recommended setup:
- Use Docker or Lume to create a sandbox VM
- Install nvm, node, npm, and bun
- Install Codex and Claude with their respective CLI tools
- Enable Claude's "Agent teams" and Codex's "Multi-agents" experimental features
- Install git and GitHub CLI
- Create a GitHub fine-grained personal access token
- Take a snapshot of your "golden image" for quick restoration
Why This Matters for Claude Code Users
This approach addresses a key limitation mentioned in our recent coverage: Claude Code agents average 25 navigation actions per code edit. By creating persistent sessions and enabling agent-to-agent communication, Loop reduces the need for constant human intervention during complex coding tasks.
The tool leverages existing agent harnesses rather than reinventing them. As the documentation notes: "The models are getting better very quickly and they are highly optimized for their respective harnesses."
Getting Started Safely
Before running Loop, ensure you have:
- Claude Code and Codex installed and logged in
- tmux for side-by-side TUIs
- Bun for building from source (prebuilt binaries don't require Bun)
For Playwright testing support:
bun x playwright install chromium
Loop stores paired run state under ~/.loop/runs/... so runs can be resumed by run ID or session/thread ID, making it suitable for long-running development tasks.



