
Container Use MCP Server
Each coding agent gets its own container and git branch, so several can work at once.
- Needs your setup first
- ★ 4.1K GitHub stars
- Last commit 21 Sept 2026
What is Container Use?
Container Use is Dagger's open source MCP server and command line tool that gives coding agents their own container and git branch, so several can work in parallel without touching your files.
- Tools
- 15
- Runs on
- Your computer
- Licence
- Apache-2.0
- GitHub stars
- 4.1K
Good for
- Running two or three coding agents in parallel without them colliding
- Letting an agent try risky changes you can throw away
- Seeing exactly what an agent ran, not just what it reports
You'll need
- macOS or Linux (Windows is not supported)
- Docker (or another runtime Dagger supports)
- git
Needs your setup firstIt needs something our Linux test machine does not have (an account, a desktop app, a Mac or a running service), so on 27 Oct 2026 we read its tools from the source code instead of running this config.
MCP Shelf take
Container Use needs something our Linux test machine does not have (an account, an app or a service), so on 27 Oct 2026 we read its source and counted 15 tools. None of them is read-only, so keep "ask before each tool call" on. It sits 4th of 5 in its category on our shelf by GitHub stars (4.1K).
What can Container Use read and change?
It can read
- Your git repository, which it copies into each environment
It can change
- Files inside environment containers, never your working copy directly
- New git branches for each environment
- Containers and images on your machine, through Docker
Safer setup: That is the point of the tool: the agent works in containers on separate branches, and nothing reaches your branch until you run cu apply or cu merge.
Container Use in more detail
Container Use comes from Dagger, the team behind the CI engine. Instead of letting an agent edit your working copy directly, each task runs in a fresh container on its own git branch. You can run several agents side by side, read the full log of commands each one ran, open a terminal inside an agent's environment when it gets stuck, and review the result with an ordinary git checkout.
It is a command line tool that also speaks MCP, and Dagger still marks it experimental. It needs Docker or another container runtime that Dagger supports.
- Made by
- Dagger (dagger/container-use)
- Last commit
- 21 Sept 2026
- Setup checked
- 27 Oct 2026
- Page updated
- 27 Oct 2026
What's in the pod
What tools does Container Use have?
We found 15 tools in its source code on 27 Oct 2026. 0 only read. The rest can change things, so keep your app's "ask before each tool call" setting on for them.
How we tested it: Read from the Go source on the main branch. Container Use ships as a compiled binary that needs Docker and Dagger, which our test machine could not run.
Runs commands1 tool · Can start programs or run code.
| Tool | What it is for |
|---|---|
environment_run_cmd | Runs a shell command in a fresh container inside the environment, in the background if needed, and can expose ports. |
Changes things14 tools · Can create, edit, send or delete.
| Tool | What it is for |
|---|---|
environment_add_service | Adds a side container, such as a database or a cache, that the environment can reach. |
environment_checkpoint | Saves the environment's current state as a container image. |
environment_config | Changes the base image and setup commands for an environment. |
environment_create | Starts a new environment from your repository: a container plus its own git branch, built from a base image and your setup commands. |
environment_diff | Shows everything the agent changed since the environment was created, as one diff. |
environment_file_delete | Deletes a file in the environment. |
environment_file_edit | Replaces a piece of text in a file in the environment. |
environment_file_list | Lists a folder in the environment. |
environment_file_read | Reads a file in the environment, whole or by line range. |
environment_file_write | Writes a whole file in the environment. |
environment_list | Lists the environments that exist for the repository. |
environment_log | Shows the commits the agent made and the commands it ran. |
environment_open | Reopens an environment created earlier. |
environment_update_metadata | Changes an environment's title, the note that says what work it holds. |
Grouped and described by us. The README on GitHub lists the inputs each tool takes.
How do I install Container Use?
Install steps from the Container Use README
The project's own instructions, copied from its README on GitHub on 27 Oct 2026 under its Apache-2.0 licence. They are the source of truth; the ready-made configs further down are built from them. The rest of the README is in the README tab.
Quick Start
Install
# macOS (recommended)
brew install dagger/tap/container-use
# All platforms
curl -fsSL https://raw.githubusercontent.com/dagger/container-use/main/install.sh | bash
Setup with Your Agent
Container Use works with any MCP-compatible agent. The setup is always the same: add container-use stdio as an MCP server.
👉 Complete setup guide for all agents (Cursor, Goose, VSCode, etc.)
Example with Claude Code:
# Add Container Use MCP server
cd /path/to/repository
claude mcp add container-use -- container-use stdio
# Add agent rules (optional)
curl https://raw.githubusercontent.com/dagger/container-use/main/rules/agent.md >> CLAUDE.md
💡 Command Shortcut
The container-use command is also available as cu for convenience. Both commands work identically:
container-use stdio(used in documentation)cu stdio(shortcut)
Try It
Ask your agent to create something:
Create a hello world app in python using flask
Your agent will work in an isolated environment and give you URLs to view the app and explore the code!
What you need first
- macOS or Linux (Windows is not supported)
- Docker (or another runtime Dagger supports)
- git
Steps
- Install the CLI: brew install dagger/tap/container-use on macOS, or the install script from the repository on Linux.
- In Claude Code, from your repository: claude mcp add container-use -- container-use stdio. Other clients use the config below.
- Optional: append the project's agent rules file to your CLAUDE.md or AGENTS.md so the agent always works inside an environment.
Add Container Use to your app
Pick your app for a ready-to-paste snippet and where it goes, built from the steps above.
Where it goes: Your terminal, in the project folder
claude mcp add container-use -- container-use stdioRun it from inside your repository. Optionally add the agent rules: curl https://raw.githubusercontent.com/dagger/container-use/main/rules/agent.md >> CLAUDE.md.
Where it goes: ~/.cursor/mcp.json, or .cursor/mcp.json in a project
{
"mcpServers": {
"container-use": {
"command": "container-use",
"args": [
"stdio"
]
}
}
}Where it goes: claude_desktop_config.json (Settings → Developer → Edit Config)
{
"mcpServers": {
"container-use": {
"command": "container-use",
"args": [
"stdio"
]
}
}
}Where it goes: .vscode/mcp.json in your project
{
"servers": {
"container-use": {
"type": "stdio",
"command": "container-use",
"args": [
"stdio"
]
}
}
}Where it goes: ~/.codex/config.toml, shared by the Codex CLI, IDE extension and ChatGPT desktop app
[mcp_servers.container-use]
command = "container-use"
args = ["stdio"]Or run: codex mcp add container-use -- container-use stdio
Where it goes: ~/.codeium/windsurf/mcp_config.json
{
"mcpServers": {
"container-use": {
"command": "container-use",
"args": [
"stdio"
]
}
}
}Where it goes: Not supported
Not supported: it runs containers on your own machine, and ChatGPT only connects to remote servers.
The shorter cu command works too: cu stdio.
Checked against the project's own install docs on 27 Oct 2026: dagger/container-use README, container-use.com/quickstart.
Did this work for you?
Projects change their install steps often. If Container Use did not install, or something here no longer matches the project, tell us and we will check it against the README and fix the page.
New to this? See the setup guides for Claude Code, Cursor, Claude Desktop, VS Code, Codex and ChatGPT. If it will not start, test it in MCP Inspector and look up the error in Fixing MCP server errors.
Container Use not working? Common fixes
- Creating an environment fails straight away
- Docker (or another runtime Dagger supports) must be running. Container Use reports Docker errors with the fix.
- The agent edits your files directly instead
- Add the project's agent rules file to CLAUDE.md or AGENTS.md, and turn off the client's own file and shell tools for that session.
- Every environment reinstalls the same packages
- Move the installs into cu config setup-command so they are part of the environment's build.
- A service the agent started is not reachable
- Ask it to expose the port in environment_run_cmd; the result gives the address to open.
How do I configure Container Use?
Names are exactly as the project spells them. Required ones are marked.
| Setting | What it does |
|---|---|
cu config base-image setConfig | The container image new environments start from.cu config base-image set python:3.12 |
cu config setup-command addConfig | Commands that run when an environment is built, such as installing system packages.cu config setup-command add "apt-get install -y postgresql-client" |
cu config env setConfig | Environment variables available inside every environment. |
cu log / cu diffCommand line flag | Show an environment's history or changes from your own terminal. |
cu terminalCommand line flag | Opens a shell inside an agent's environment so you can look around or take over. |
cu checkout / cu apply / cu mergeCommand line flag | Bring an environment's work into your repository: switch to its branch, stage its changes, or merge it. |
Container Use FAQ
How do I install Container Use?
On macOS, brew install dagger/tap/container-use. On Linux, run the install script from the repository. Then add container-use stdio as an MCP server in your agent. You need Docker or another runtime Dagger supports.
How do I use Container Use with Claude Code?
From your repository, run claude mcp add container-use -- container-use stdio, and add the project's agent rules to CLAUDE.md so Claude works inside environments instead of on your files.
How do I review what a Container Use agent did?
cu log and cu diff show its commands and changes, cu terminal drops you into its container, and cu checkout, cu apply or cu merge bring the work into your branch when you are happy.
Is Container Use safe?
That is its purpose: each agent works in a container on its own branch, and nothing reaches your branch until you apply or merge it. Treat the container as untrusted until you have read the diff.
Is Container Use free?
Yes. It is Apache 2.0 licensed and runs on your own machine with your container runtime, so there is no service to pay for.
Does Container Use work on Windows?
No. Its installer refuses Windows because the tool relies on Unix system calls. Use macOS or Linux.
Is Container Use stable?
Dagger marks it experimental, and it changes between releases. It works, but expect rough edges and check the release notes when you update.
Why does every Container Use environment reinstall the same packages?
Set them once for the project: cu config base-image set picks the image, and cu config setup-command add runs your install steps for every new environment.
Container Use README
This is the project's own README from dagger/container-use, written by Dagger (dagger/container-use), and shared under its Apache-2.0 licence. We copied it on 27 Oct 2026, so the version on GitHub may be newer.
container-use
Containerized environments for coding agents. (📦🤖) (📦🤖) (📦🤖)
Container Use lets coding agents do their work in parallel environments without getting in your way. Go from babysitting one agent at a time to enabling multiple agents to work safely and independently with your preferred stack. See the full documentation.
It's an open-source MCP server that works as a CLI tool with Claude Code, Cursor, and other MCP-compatible agents. Powered by Dagger.
- 📦 Isolated Environments: Each agent gets a fresh container in its own git branch - run multiple agents without conflicts, experiment safely, discard failures instantly.
- 👀 Real-time Visibility: See complete command history and logs of what agents actually did, not just what they claim.
- 🚁 Direct Intervention: Drop into any agent's terminal to see their state and take control when they get stuck.
- 🎮 Environment Control: Standard git workflow - just
git checkout <branch_name>to review any agent's work. - 🌎 Universal Compatibility: Works with any agent, model, or infrastructure - no vendor lock-in.
🦺 This project is in early development and actively evolving. Submit issues and/or reach out to us on Discord in the #container-use channel.
Quick Start
Install
# macOS (recommended)
brew install dagger/tap/container-use
# All platforms
curl -fsSL https://raw.githubusercontent.com/dagger/container-use/main/install.sh | bash
Setup with Your Agent
Container Use works with any MCP-compatible agent. The setup is always the same: add container-use stdio as an MCP server.
👉 Complete setup guide for all agents (Cursor, Goose, VSCode, etc.)
Example with Claude Code:
# Add Container Use MCP server
cd /path/to/repository
claude mcp add container-use -- container-use stdio
# Add agent rules (optional)
curl https://raw.githubusercontent.com/dagger/container-use/main/rules/agent.md >> CLAUDE.md
💡 Command Shortcut
The container-use command is also available as cu for convenience. Both commands work identically:
container-use stdio(used in documentation)cu stdio(shortcut)
Try It
Ask your agent to create something:
Create a hello world app in python using flask
Your agent will work in an isolated environment and give you URLs to view the app and explore the code!
Two peas, one chat
Chat with AI about Container Use
Opens a chat primed with Container Use’s README and setup docs from this page, or add it in Cursor to use its tools.
The Cursor button opens Cursor and asks before it adds the server. Fill in any keys it needs in Cursor’s MCP settings.
Peas in a pod
What are the alternatives to Container Use?
How Container Use lines up against its neighbours on the shelf. See every agent helpers and desktop control server.

Container UseThis pea
Each coding agent gets its own container and git branch, so several can work at once.
- Tools
- 15
- Runs on
- Your computer
- Licence
- Apache-2.0
- Stars
- 4.1K

Lets an assistant explore and command a ROS or ROS 2 robot through rosbridge.
- Tools
- 31
- Runs on
- Your computer
- Licence
- Apache-2.0
- Stars
- 1.5K

A numbered scratchpad the model fills in, revises and branches while it works.
- Tools
- 1
- Runs on
- Your computer
- Licence
- MIT / Apache-2.0
- Stars
- 91.6K

Mouse, keyboard, apps, files and PowerShell on a Windows PC, driven by your assistant.
- Tools
- 21
- Runs on
- Your computer
- Licence
- MIT
- Stars
- 10.6K

Tap, swipe, type and read the screen on iOS and Android, real or simulated.
- Tools
- 34
- Runs on
- Your computer
- Licence
- Apache-2.0
- Stars
- 10.1K
Something wrong on this page? Tell us.
For bots & AI agents
Machine-readable versions of Container Use and MCP Shelf. Fetch these instead of parsing this page.
This listing (.md)llms.txtllms-full.txtai.txtFull catalog (.md)API specMCP serverMCP manifestDeveloper docs