> ## Documentation Index
> Fetch the complete documentation index at: https://docs.boxlite.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Tutorials

> Step-by-step tutorials that teach you to solve real problems with BoxLite — execute code, transfer files, connect LLMs, and automate browsers.

You've installed BoxLite and run "Hello from BoxLite!" — now what? These tutorials walk you through the most common tasks, with working code you can copy and adapt.

## Which box type should I use?

| I want to...                         | Use                                                                                                                  | Tutorial                                                  |
| ------------------------------------ | -------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------- |
| Run Claude Code in a sandbox         | [**SimpleBox**](/getting-started/core-concepts#box-types)                                                            | [Claude Code](/tutorials/ai-coding-tools)                 |
| Run a shell command in isolation     | [**SimpleBox**](/getting-started/core-concepts#box-types)                                                            | [Quick Start](/getting-started/quickstart-python)         |
| Execute AI-generated Python code     | [**CodeBox**](/getting-started/core-concepts#box-types)                                                              | [Execute AI-generated code](/tutorials/code-execution)    |
| Upload and download files            | [**SimpleBox**](/getting-started/core-concepts#box-types) or [**CodeBox**](/getting-started/core-concepts#box-types) | [Upload & download files](/tutorials/file-transfer)       |
| Connect an LLM to a sandbox          | [**CodeBox**](/getting-started/core-concepts#box-types)                                                              | [Connect to an LLM](/tutorials/llm-integration)           |
| Automate a browser                   | [**BrowserBox**](/getting-started/core-concepts#box-types)                                                           | [Automate a browser](/tutorials/browser-automation)       |
| Control a full desktop               | [**ComputerBox**](/getting-started/core-concepts#box-types)                                                          | [Automate a desktop](/tutorials/desktop-automation)       |
| Run an interactive shell session     | [**InteractiveBox**](/getting-started/core-concepts#box-types)                                                       | [Interactive terminal](/tutorials/interactive-terminal)   |
| Run Node.js, Go, Rust, or any tool   | [**SimpleBox**](/getting-started/core-concepts#box-types)                                                            | [Run any language](/tutorials/run-any-language)           |
| Run a server and access it from host | [**SimpleBox**](/getting-started/core-concepts#box-types)                                                            | [Long-running services](/tutorials/long-running-services) |
| Handle errors and debug failures     | All                                                                                                                  | [Error handling](/tutorials/error-handling)               |

<Tip>
  Not sure? Start with [**CodeBox**](/getting-started/core-concepts#box-types) — it handles the most common AI agent use case (running untrusted code) and auto-installs packages for you. See [Core concepts](/getting-started/core-concepts) for a full explanation of each box type.
</Tip>

## All tutorials

<CardGroup cols={2}>
  <Card title="Run Claude Code in a sandbox" icon="microchip" href="/tutorials/ai-coding-tools">
    Run Anthropic's Claude Code agent inside an isolated VM for safe, autonomous code generation and execution.
  </Card>

  <Card title="Execute AI-generated code" icon="code" href="/tutorials/code-execution">
    Create a CodeBox, run untrusted Python code, auto-install packages, and get output safely. Python and Node.js examples.
  </Card>

  <Card title="Upload & download files" icon="arrows-rotate" href="/tutorials/file-transfer">
    Move files in and out of a sandbox using copy\_in/copy\_out, volume mounts, or inline base64. Three methods compared.
  </Card>

  <Card title="Connect to an LLM" icon="robot" href="/tutorials/llm-integration">
    Give any LLM the ability to execute code inside a BoxLite sandbox via tool calling. Examples for OpenAI, Anthropic, and Vercel AI SDK.
  </Card>

  <Card title="Automate a browser" icon="globe" href="/tutorials/browser-automation">
    Launch a BrowserBox, connect via Chrome DevTools Protocol, take a screenshot, and scrape a page with Puppeteer or Playwright.
  </Card>

  <Card title="Automate a desktop" icon="desktop" href="/tutorials/desktop-automation">
    Launch a ComputerBox with a full GUI desktop, control the mouse and keyboard, and take screenshots.
  </Card>

  <Card title="Interactive terminal" icon="terminal" href="/tutorials/interactive-terminal">
    Launch an InteractiveBox with PTY support, run shell sessions, and connect to REPLs.
  </Card>

  <Card title="Run any language or tool" icon="toolbox" href="/tutorials/run-any-language">
    Use SimpleBox with custom images to run Node.js, shell scripts, or any CLI tool — not just Python.
  </Card>

  <Card title="Run services with port forwarding" icon="server" href="/tutorials/long-running-services">
    Start HTTP servers and JSON APIs inside a sandbox, forward ports, and access them from the host.
  </Card>

  <Card title="Handle errors and debug" icon="bug" href="/tutorials/error-handling">
    Check exit codes, catch exceptions, handle timeouts, and stream stderr in real time.
  </Card>
</CardGroup>

## What's next?

Once you've worked through these tutorials, dive into the [Guides](/guides/index) for advanced patterns like concurrency, timeout handling, security configuration, and production deployment.
