E2B
Summary
Run AI-generated code safely in an isolated cloud sandbox, with results returned as data rather than text.
Features
- Run code in an isolated cloud sandbox
- Stateful sessions across multiple executions
- Returns charts, tables, and files as structured results
Installation
Set up this MCP server in your favorite AI agent — copy a ready-made configuration below.
Description
The E2B MCP server gives an assistant a real computer to run code on — isolated, disposable, and started in well under a second.
What it enables
- Code execution in a sandboxed cloud VM with a Python runtime and internet access
- Stateful sessions. Variables and imports persist between executions, so an assistant can build up an analysis step by step the way a person would in a notebook.
- Rich results. Charts come back as images, DataFrames as structured tables — not as text descriptions of what the output would have looked like.
- File handling for uploading data and retrieving generated artefacts
Why the isolation matters
Any assistant that writes code will eventually want to run it, and running model-generated code on your own machine is a category of risk not worth taking. The sandbox contains mistakes and prompt injection alike, and it is destroyed when the task ends.
Common uses
Data analysis over an uploaded file, verifying that generated code actually works before handing it over, mathematical computation, and any task where executing is more reliable than reasoning.
Requires an E2B API key; runs with npx @e2b/mcp-server. Free tier available.
Related MCP Servers
mcp-remote
by Glen Maddern
A proxy that lets local-only MCP clients connect to remote servers, handling OAuth and transport differences.
Blender
by Siddharth Ahuja
Control Blender from an AI client — build scenes, apply materials, and run Python against the live session.
ElevenLabs
by ElevenLabs
ElevenLabs' official MCP server — generate speech, clone voices, transcribe audio, and build voice agents.

Patchloom
by Patchloom
Structured, format-preserving file editor for agents: JSON/YAML/TOML, markdown, and AST-aware code edits, transactional across files.