Which box type should I use?
| I want to… | Use | Tutorial |
|---|---|---|
| Run Claude Code in a sandbox | SimpleBox | Claude Code |
| Run a shell command in isolation | SimpleBox | Quick Start |
| Execute AI-generated Python code | CodeBox | Execute AI-generated code |
| Upload and download files | SimpleBox or CodeBox | Upload & download files |
| Connect an LLM to a sandbox | CodeBox | Connect to an LLM |
| Automate a browser | BrowserBox | Automate a browser |
| Control a full desktop | ComputerBox | Automate a desktop |
| Run an interactive shell session | InteractiveBox | Interactive terminal |
| Run Node.js, Go, Rust, or any tool | SimpleBox | Run any language |
| Run a server and access it from host | SimpleBox | Long-running services |
| Handle errors and debug failures | All | Error handling |
All tutorials
Run Claude Code in a sandbox
Run Anthropic’s Claude Code agent inside an isolated VM for safe, autonomous code generation and execution.
Execute AI-generated code
Create a CodeBox, run untrusted Python code, auto-install packages, and get output safely. Python and Node.js examples.
Upload & download files
Move files in and out of a sandbox using copy_in/copy_out, volume mounts, or inline base64. Three methods compared.
Connect to an LLM
Give any LLM the ability to execute code inside a BoxLite sandbox via tool calling. Examples for OpenAI, Anthropic, and Vercel AI SDK.
Automate a browser
Launch a BrowserBox, connect via Chrome DevTools Protocol, take a screenshot, and scrape a page with Puppeteer or Playwright.
Automate a desktop
Launch a ComputerBox with a full GUI desktop, control the mouse and keyboard, and take screenshots.
Interactive terminal
Launch an InteractiveBox with PTY support, run shell sessions, and connect to REPLs.
Run any language or tool
Use SimpleBox with custom images to run Node.js, shell scripts, or any CLI tool — not just Python.
Run services with port forwarding
Start HTTP servers and JSON APIs inside a sandbox, forward ports, and access them from the host.
Handle errors and debug
Check exit codes, catch exceptions, handle timeouts, and stream stderr in real time.

