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

# Deploy

> Deploy your agent to the sb0 platform

## Prerequisites

<Info>
  This step requires Docker to be installed and running on your machine. To install Docker, follow the [official installation guide](https://docs.docker.com/get-started/get-docker/).
</Info>

## Authenticate

First, authenticate your CLI with the sb0 platform:

```bash theme={null}
sb0 login
```

The deployment flow is simple:

<Steps>
  <Step title="Build">
    Build your agent into a Docker image:

    ```bash theme={null}
    sb0 agent build
    ```

    This packages your agent code, dependencies, and runtime into a production-ready container.

    **Expected output:**

    ```
    Building Docker image my-agent:latest...
    ...
    ✔ Image built: my-agent:latest
    ```
  </Step>

  <Step title="Push">
    From your `agent/` directory, push your agent to the platform:

    ```bash theme={null}
    sb0 push
    ```

    This builds and uploads your agent to the sb0 platform registry.

    **Expected output:**

    ```
    Building agent...
    Pushing to platform registry...
    ✔ Agent published successfully
    ```

    <Tip>
      `sb0` uses the latest available version of your agent.
    </Tip>
  </Step>

  <Step title="Test">
    Test your deployed agent:

    ```bash theme={null}
    sb0 query "test question"
    ```
  </Step>
</Steps>
