What do you want to do?
3 use cases
-
Sandbox an MCP server with one line in .mcp.json
Wrap a local MCP server in srt so it can only write and connect where you allow.
View prompt
Install anthropics/sandbox-runtime and wrap my <MCP server> in srt in .mcp.json. Write ~/.srt-settings.json so it can write only to <allowed path> and reach only <allowed domains>, then prove it by asking it to write to <denied path> and showing me the error.
-
Keep agent shell commands away from your SSH keys
Run bash commands through srt so they get no network by default and cannot read the files you deny.
View prompt
Using anthropics/sandbox-runtime, write an srt settings file for <project> that allows network only to <domains>, denies reads of ~/.ssh and **/.env, and allows writes only to the project folder. Run <command> under it with `srt --settings` and report anything that was blocked.
-
Change network rules while a sandboxed command runs
Feed srt new configs through a control channel so an orchestrator can open or close domains mid-run.
View prompt
Wrap <long running command> with anthropics/sandbox-runtime using --control-fd from my harness. Start with no network access, then send a config line that allows <domain> when the task needs it and remove it afterwards. Log every config line srt accepted or rejected.
Quick start with Sandbox Runtime
- Check you have what it needs: Node.js and npm to install the CLI; macOS, Linux with bubblewrap, or Windows; Optional: a settings file at ~/.srt-settings.json; without one srt uses built-in defaults.
- Open anthropics/sandbox-runtime on GitHub and read the README and license.
- Run
npm install -g @anthropic-ai/sandbox-runtime - In .mcp.json, change the server's command to srt and move the original command into args, for example
"command": "srt"with"args": ["npx", "-y", "@modelcontextprotocol/server-filesystem"] - Create ~/.srt-settings.json with filesystem rules (denyRead, allowWrite, denyWrite) and network rules (allowedDomains, deniedDomains)
- Restart your agent and ask the MCP server to write to a denied path to confirm it gets EPERM
These steps come from our top use case, Sandbox an MCP server with one line in .mcp.json, which also has a copy-paste agent prompt.
Use this in your AI agent
Ask your agent
Using the Deduped MCP, get the setup steps for anthropics/sandbox-runtime
Add Deduped to Claude Code once
claude mcp add --transport http deduped https://dedupedai.com/mcp
Every Monday: the 5 hottest repos and exactly how to use them. Free, one email a week, unsubscribe anytime.
Get them freeSandbox Runtime alternatives · Best AI repos for Software and DevOps
About this repo
- Who it is forDevelopers running AI agents, MCP servers or untrusted scripts who want a quick allowlist for files and network without setting up Docker.
- Why it is hot6.5k stars, talked about in 2 AI sources we track
- LanguageTypeScript
- Sourcegithub.com/anthropics/sandbox-runtime · Back to Hot repos
Requirements
- Node.js and npm to install the CLI
- macOS, Linux with bubblewrap, or Windows
- Optional: a settings file at ~/.srt-settings.json; without one srt uses built-in defaults
Add this badge to your README
Maintain Sandbox Runtime? Show readers where to find these use cases.
Markdown
[](https://dedupedai.com/use-cases/anthropics-sandbox-runtime/?utm_source=github&utm_medium=badge&utm_campaign=anthropics-sandbox-runtime)
HTML
<a href="https://dedupedai.com/use-cases/anthropics-sandbox-runtime/?utm_source=github&utm_medium=badge&utm_campaign=anthropics-sandbox-runtime"><img src="https://dedupedai.com/badge/anthropics/sandbox-runtime.svg" alt="Use cases on Deduped" height="20"></a>
A static image, no tracking script. About the badge
Questions about Sandbox Runtime
What is Sandbox Runtime?
Anthropic Sandbox Runtime (srt) is a lightweight tool that enforces filesystem and network restrictions on any process at the OS level, without a container. It uses sandbox-exec on macOS, bubblewrap on Linux and a dedicated local account on Windows, plus proxy-based network filtering, and was built for Claude Code to sandbox agents, local MCP servers and bash commands. It is an open-source project on GitHub: https://github.com/anthropics/sandbox-runtime.
How do I use Sandbox Runtime?
Run npm install -g @anthropic-ai/sandbox-runtime; then in .mcp.json, change the server's command to srt and move the original command into args, for example "command": "srt" with "args": ["npx", "-y", "@modelcontextprotocol/server-filesystem"]; create ~/.srt-settings.json with filesystem rules (denyRead, allowWrite, denyWrite) and network rules (allowedDomains, deniedDomains). The use cases on this page give the full steps and a copy-paste agent prompt for each job.
Who is Sandbox Runtime for?
Developers running AI agents, MCP servers or untrusted scripts who want a quick allowlist for files and network without setting up Docker.
What can I do with Sandbox Runtime?
3 use cases so far, for example: Sandbox an MCP server with one line in .mcp.json; Keep agent shell commands away from your SSH keys; Change network rules while a sandboxed command runs. Each has steps and a copy-paste agent prompt.
What do I need to run Sandbox Runtime?
Node.js and npm to install the CLI; macOS, Linux with bubblewrap, or Windows; Optional: a settings file at ~/.srt-settings.json; without one srt uses built-in defaults.
What are alternatives to Sandbox Runtime?
Other hot AI repos in Software and DevOps: Deep Infer, Harness2, Orca, Opencode, Graphify.
Is Sandbox Runtime safe to run?
Deduped does not own, audit or vouch for it. Read the README and license, run it on your own systems first and review every command before you run it.