Sandboxes for AI agents to run code (2026)
Sandboxes and isolated runtimes where agents can run code and tools away from your machine and data. Here are the top 25 of 145 from the AgentScout directory.
Quick answer: the top picks on this list, ranked by GitHub stars and listing maturity, are Filesystem MCP Server, Deer Flow and AstrBot, out of 25 tools listed below. At a glance: 22 open-source, 24 free or freemium and 22 local or self-hosted across 25 link-checked tools (last verified ).
Verified on : every tool link on this page was checked by our daily link check. No paid placements.
Ranked comparison (top 10)
| # | Tool | Pricing | Best for | Open source | Runs locally | GitHub stars |
|---|---|---|---|---|---|---|
| 1 | Open source | research the web, connect tools via MCP | Yes | Self-hosted | 92,454 | |
| 2 | Open source | write code, build an agent | Yes | Self-hosted | 86,076 | |
| 3 | Open source | build an agent, automate workflows | Yes | Self-hosted | 47,869 | |
| 4 | Source-available + cloud | write code, run code safely | No | 34,699 | ||
| 5 | Open source + cloud | automate the browser, control a computer | Yes | Self-hosted | 33,792 | |
| 6 | Open source | build an agent, run code safely | Yes | Self-hosted | 31,764 | |
| 7 | Freemium | write code, build an agent | No | 31,403 | ||
| 8 | Open source | build multi-agent systems, build an agent | Yes | Self-hosted | 30,989 | |
| 9 | Open source | write code, build an agent | Yes | Offline | 30,633 | |
| 10 | Freemium | automate the browser, automate workflows | No | 25,877 |
Updated
How we picked and ranked: tools are matched by category, the pricing each maker states and what each tool says it does. They are ranked by GitHub stars as recorded on each listing (link checks 2026-12-04); tools without a tracked repo follow, by listing maturity. No paid placements.

1. Filesystem MCP Server
The official Filesystem MCP Server from the Model Context Protocol project gives Claude, Cursor, VS Code and other MCP clients sandboxed read, write, edit, search and move access to only the folders you allow, installed with npx @modelcontextprotocol/server-filesystem or the mcp/filesystem Docker image.
Pricing (as stated): Free and open source (MIT, moving to Apache-2.0 for new contributions) · Mature

2. Deer Flow
DeerFlow 2.0 is ByteDance's MIT-licensed super-agent harness for long tasks that can take minutes to hours, such as research reports, coding jobs and content creation. It coordinates sub-agents, long-term memory, sandboxed code execution, tools and extensible skills, and can take requests through a message gateway; version 2.0 is a ground-up rewrite, with the original Deep Research framework kept on a separate branch.
Pricing (as stated): Free and open source (MIT); you supply your own model API keys. · Mature

3. AstrBot
AstrBot is an AGPL-3.0, all-in-one agent chatbot platform that connects LLMs to messaging apps such as QQ, WeChat Work, Feishu, DingTalk, WeChat Official Accounts, Telegram and Slack. It supports multimodal chat, agents, MCP, skills, knowledge bases, personas and automatic context compression, integrates with Dify, Alibaba Cloud Bailian and Coze, offers an agent sandbox, and has 1,000+ one-click plugins for building personal assistants, support bots or team knowledge bots.
Pricing (as stated): Open source · Mature

4. Context Mode
Context window optimizer for coding agents that sandboxes tool output and persists session memory.
Pricing (as stated): Source-available + cloud · Mature

5. Cua
Open-source infrastructure for computer-use agents: sandboxes, drivers across operating systems and benchmarks.
Pricing (as stated): Open source + cloud · Mature

6. LangChain Deep Agents
Deep Agents is LangChain's MIT-licensed, batteries-included agent harness for long-horizon, multi-step work: an opinionated agent that runs out of the box and lets you override or replace any piece. It provides sub-agents with isolated context windows, a pluggable filesystem (local, sandboxed or remote), context summarisation and offloading, shell access in your sandbox, persistent memory and human-in-the-loop approvals. It is model-agnostic for any tool-calling LLM and builds on LangGraph, with tracing, evals and deployment through LangSmith.
Pricing (as stated): Open source · Active

7. Composio
Composio gives AI agents more than 1,000 pre-authenticated toolkits for apps such as Gmail, Slack, GitHub and Salesforce, with per-user sessions, managed OAuth, tool search, triggers and a sandboxed workbench, so an agent can act in a user's accounts without you building each integration. The MIT-licensed monorepo ships TypeScript and Python SDKs, a CLI for searching and running tools from the shell, and adapters for the OpenAI Agents SDK, Claude Agent SDK, Vercel AI SDK, LangChain and more; the hosted platform has a free tier.
Pricing (as stated): Free tier + paid plans · Mature

8. OpenAI Agents SDK (Python)
The OpenAI Agents SDK for Python is an MIT-licensed, lightweight framework for multi-agent workflows. Agents are LLMs with instructions, tools, guardrails and handoffs; sandbox agents work inside a container over long time horizons; realtime and voice agents cover speech pipelines; and built-in tracing shows each run. It is provider-agnostic, working with the OpenAI Responses and Chat Completions APIs and 100+ other LLMs, and has a JavaScript/TypeScript sibling (openai-agents-js).
Pricing (as stated): Open source · Mature, official SDK

9. smolagents
smolagents is Hugging Face's Apache-2.0 Python library for agents that think in code: its CodeAgent writes each action as a Python snippet rather than a JSON tool call, and the core agent logic fits in about 1,000 lines. Generated code can run in sandboxes such as E2B, Modal, Blaxel or Docker, tools and agents can be shared to and pulled from the Hugging Face Hub, and it works with any model, from local transformers or Ollama to OpenAI, Anthropic and other providers via LiteLLM.
Pricing (as stated): Open source · Active

10. ego lite
Free macOS browser where Claude Code or Codex run automation tasks in their own isolated Spaces next to your tabs, reusing your logged-in sessions through an agent skill.
Pricing (as stated): Freemium · Mature

11. NemoClaw
NVIDIA's open-source reference stack for running agents such as OpenClaw, Hermes and LangChain Deep Agents inside NVIDIA OpenShell sandboxes. It adds guided onboarding, managed inference, network policy and lifecycle commands through a CLI.
Pricing (as stated): Open source · Active

12. NVIDIA OpenShell
NVIDIA OpenShell is an Apache-2.0 runtime for fleets of agents. Each agent runs in its own sandbox, and declarative policies decide which files, networks, packages, and credentials it may touch. The project is now part of the CNCF, and the project does not list a paid plan.
Pricing (as stated): Open source (Apache-2.0). No paid plan is listed. Checked 2 Dec 2026. · Active; part of newly announced Open Agent Safety Platform

13. Keploy
Keploy records API traffic and turns it into isolated integration and end-to-end tests
Pricing (as stated): Open-source (Apache-2.0); see site for any hosted plans · Mature

14. Agent Zero
Agent Zero is an open-source AI agent that gets its own Linux computer: inside a Docker sandbox it uses a terminal, a browser and desktop apps to research, write and run code, and create and edit documents, building its own tools and correcting itself as it goes. You watch and can step in through a web UI, connect local folders when needed, and choose the models it uses. It is actively developed, with v2.16 released in November 2026.
Pricing (as stated): Open source · Mature

15. HTML Anything
An agentic HTML editor from the Open Design team. Your local coding-agent CLI (Claude Code, Cursor, Codex, Gemini and others) writes HTML decks, posters, reports and prototypes from 75 skills, shows them in a sandboxed preview, and exports in one click. No API key is needed.
Pricing (as stated): Open source · Active

16. OpenSandbox
Secure, fast sandbox runtime for AI agents to run code.
Pricing (as stated): Open source · Mature

17. OpenMetadata
OpenMetadata is an open platform that keeps one context layer for people, assistants and agents. It joins technical metadata, quality signals, lineage, ownership, glossaries and data products in a single knowledge graph. More than 150 connectors feed that graph, and an MCP server lets an assistant query it. The site offered a free live sandbox and a free cloud signup beside the open-source project. A release was published on 24 Nov 2026. GitHub recorded Apache-2.0, 15,940 stars and 2,558 forks on 2 Dec 2026.
Pricing (as stated): Apache-2.0. The site offered a free sandbox and a free cloud signup, and a managed service, with no dollar price on the pages checked. Checked 2 Dec 2026. · Mature

18. E2B
Secure cloud sandboxes for running agent-generated code.
Pricing (as stated): Open source + paid cloud · Mature

19. CubeSandbox
Lightweight, concurrent sandbox for running AI agent code securely.
Pricing (as stated): Open source · Mature

20. Open SWE
LangChain's asynchronous coding agent that takes work from GitHub issues, Slack or Linear, implements it in an isolated sandbox and opens a pull request.
Pricing (as stated): Open source · Mature

21. Rakazo
Self-hosted personal AI agent and persistent teammate for web, desktop, iPhone and Android, with your own choice of model and computer sandbox.
Pricing (as stated): Open source · Active

22. Claurst
Claurst is a GPL-3.0 terminal coding agent written in Rust that began as a clean-room reimplementation of Claude Code's behaviour and now works with several model providers, with a rich TUI, plugins, hooks, chat forking, memory consolidation, per-command approvals and, on macOS, a sandbox that limits shell writes to the workspace and blocks network by default; it has no telemetry and is in beta.
Pricing (as stated): Open source · Mature

23. microsandbox
Local-first microVM runtime for running untrusted agent code safely.
Pricing (as stated): Open source · Mature

24. Agent Substrate
Agent Substrate runs each agent in its own microVM or gVisor sandbox with an identity, no credentials and no open network, suspending idle agents and resuming in under 500ms.
Pricing (as stated): Open source · Mature

25. ThinkRail
JetBrains' lightweight agentic IDE that pairs you with the pi coding agent, with isolated git-worktree workspaces, editor tabs, terminals and diffs.
Pricing (as stated): Open source · Active
FAQ
What are the best AI code sandboxes?
Ranked by tracked GitHub stars, the top AI code sandboxes in our directory are Filesystem MCP Server, Deer Flow, AstrBot, Context Mode, Cua. Stars measure popularity, not fit, so compare a few against your own task.
How many AI code sandboxes does AgentScout list?
145 tools match. This page shows the top 25. Pricing mix on this page: Open source (19), Open source + cloud (3), Freemium (2), Source-available + cloud (1).
How much do these tools cost?
Pricing is what each maker states on their site. Open-source tools are free to self-host but may need a paid model API key or offer paid cloud plans; freemium tools have a free plan with limits. Check each official site.
Where can I see every tool for running code safely?
Our task page lists all 145 tools we match to running code safely.
Related
- All tools for running code safely
- MCP servers (38)
- sandboxes & code execution (37)
- coding (12)
- browser/computer use (11)
By role
Best-of lists
Related categories
Facts come from our directory listings; pricing is as each maker states it and can change. Check official sites before you choose.