IPyBox
A Python code execution sandbox based on IPython and Docker. Stateful code execution, file transfer between host and container, configurable network access.
What is IPyBox?
IPyBox is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to python code execution sandbox based on ipython and docker. stateful code execution, file transfer between host and container, configurable network access.
A Python code execution sandbox based on IPython and Docker. Stateful code execution, file transfer between host and container, configurable network access.
This server falls under the Developer Tools category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- A Python code execution sandbox based on IPython and Docker.
Use Cases
Maintainer
Works with
Installation
PIP
pip install ipyboxManual Installation
pip install ipyboxConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use IPyBox
IPyBox is a Python code execution sandbox that combines IPython kernels with Docker containers to provide stateful, isolated code execution for AI agents. It supports unified code blocks that mix Python, shell commands, and MCP tool calls in a single session. Developers use it to give LLMs a safe, reproducible environment for running data analysis, automating workflows, and interacting with external APIs — with state persisting across executions and optional OS-level sandboxing via Anthropic's sandbox-runtime.
Prerequisites
- Python 3.8+ and pip installed on your system
- Docker installed and running (required for the sandboxed execution container)
- An MCP-compatible client such as Claude Desktop or Claude Code
- ipybox package installed via pip (pip install ipybox)
Install ipybox
Install the ipybox package from PyPI using pip. For older versions (pre-0.7), use the version constraint shown below.
pip install ipyboxEnsure Docker is running
IPyBox uses Docker to spin up isolated IPython kernels. Verify Docker is installed and the daemon is active before starting the MCP server.
docker infoStart the MCP server
Run ipybox as an MCP server using the Python module entry point. This starts the stdio-based MCP interface that clients connect to.
python -m ipyboxConfigure your MCP client
Add the ipybox MCP server to your Claude Desktop configuration file. On macOS this file is at ~/Library/Application Support/Claude/claude_desktop_config.json.
{
"mcpServers": {
"ipybox": {
"command": "python",
"args": ["-m", "ipybox"]
}
}
}Restart your MCP client
Restart Claude Desktop (or your MCP client) to pick up the new server configuration. The ipybox server will start automatically when the client launches.
Test with a stateful Python execution
Send a message to Claude asking it to run Python code. The kernel maintains state across multiple executions, so variables defined in one message are available in the next.
IPyBox Examples
Client configuration
Add ipybox to your Claude Desktop MCP configuration. The server runs via the Python module interface.
{
"mcpServers": {
"ipybox": {
"command": "python",
"args": ["-m", "ipybox"]
}
}
}Prompts to try
Once connected, you can ask Claude to execute Python code in the stateful sandbox.
- "Run a pandas analysis on this CSV data and show me summary statistics"
- "Write and execute a Python script that fetches data from an API and plots a chart"
- "Install numpy in the sandbox and compute the eigenvalues of a random matrix"
- "Run !ls -la to list files in the container, then read the output file"
- "Execute this data pipeline step by step, keeping variables between steps"Troubleshooting IPyBox
Docker container fails to start or times out
Ensure Docker Desktop is running and your user has permission to run containers. Run 'docker ps' to verify Docker is accessible, and check that no firewall rules are blocking container network access.
State is lost between messages
Each MCP session maintains a single IPython kernel. If you restart Claude Desktop or the server, a new kernel is created. Keep the client running without restarting to preserve session state across multiple code executions.
pip install ipybox fails with permission errors
Use a virtual environment: 'python -m venv .venv && source .venv/bin/activate && pip install ipybox'. Then update the MCP config to use the venv's Python: '/path/to/.venv/bin/python -m ipybox'.
Frequently Asked Questions about IPyBox
What is IPyBox?
IPyBox is a Model Context Protocol (MCP) server that python code execution sandbox based on ipython and docker. stateful code execution, file transfer between host and container, configurable network access. It connects AI assistants to external tools and data sources through a standardized interface.
How do I install IPyBox?
Install via pip with: pip install ipybox. Then configure your AI client to connect to this MCP server.
Which AI clients work with IPyBox?
IPyBox works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is IPyBox free to use?
Yes, IPyBox is open source and available under the Apache 2.0 license. You can use it freely in both personal and commercial projects.
IPyBox Alternatives — Similar Developer Tools Servers
Looking for alternatives to IPyBox? Here are other popular developer tools servers you can use with Claude, Cursor, and VS Code.
Ecc
★ 188.2kThe agent harness performance optimization system. Skills, instincts, memory, security, and research-first development for Claude Code, Codex, Opencode, Cursor and beyond.
Javaguide
★ 155.8kJava 面试 & 后端通用面试指南,覆盖计算机基础、数据库、分布式、高并发、系统设计与 AI 应用开发
Gemini CLI
★ 104.5kA secure MCP server that wraps the Google Gemini CLI, allowing clients to query Gemini models using local OAuth sessions without requiring an API key. It provides tools for model interaction and diagnostics with built-in protection against command in
Awesome MCP Servers
★ 87.3k⭐ Curated list of Model Context Protocol (MCP) servers - tools that extend Claude Desktop, Cursor, Windsurf, and other MCP clients with custom capabilities.
MCP Servers
★ 86.0kModel Context Protocol Servers
CC Switch
★ 77.5kA cross-platform desktop All-in-One assistant for Claude Code, Codex, OpenCode, OpenClaw, Gemini CLI & Hermes Agent. Only official website: ccswitch.io
Browse More Developer Tools MCP Servers
Explore all developer tools servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up IPyBox in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use IPyBox?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.