# Server

Source: https://zshot-cli.com/reference/server/
Markdown: https://zshot-cli.com/reference/server/index.md
Section: [Reference](https://zshot-cli.com/reference/)

[`--server`](/reference/flags/server/server) runs ZShot as an HTTP server that renders captures through its [API](/reference/server/api). It binds `127.0.0.1:3000` by default; set [`--server-bind-address`](/reference/flags/server/server-bind-address) and [`--server-bind-port`](/reference/flags/server/server-bind-port) to change that. To reach the server from another host or a container, bind `0.0.0.0`.

```sh
zshot --server --server-bind-address 0.0.0.0 --server-bind-port 3000
```

The server's routes are listed under [Endpoints](/reference/server/endpoints).

## Concurrency

The server renders one request at a time, or up to the CPU count with an Enterprise license, and holds up to 100 further requests in a queue. A queued request starts when a slot frees and returns 408 if its timeout expires first; a request that arrives when the queue is full gets 429. Every render response carries a `Server-Timing` header with `queue`, the milliseconds spent waiting for a slot, and `total`, the milliseconds from arrival to completion. A render that called a navigator or formatter model also carries `X-Zshot-LLM-Usage`, the tokens each model spent; see [`--llm-usage`](/reference/flags/diagnostics/llm-usage). [`--server-max-concurrency`](/reference/flags/server/server-max-concurrency) raises the cap and [`--server-queue-requests`](/reference/flags/server/server-queue-requests) sets the depth; `--server-queue-requests 0` turns the queue off.

To run the server in Docker, see [Docker](/reference/docker).

## Navigation

- [Examples](https://zshot-cli.com/examples/)
- [Download](https://zshot-cli.com/download/)
- [Purchase](https://zshot-cli.com/purchase/)
- [Reference](https://zshot-cli.com/reference/)
  - [Formats](https://zshot-cli.com/reference/formats/)
  - [Flags](https://zshot-cli.com/reference/flags/)
  - [Agents](https://zshot-cli.com/reference/agents/)
  - [Configuration](https://zshot-cli.com/reference/configuration/)
  - [Crawling](https://zshot-cli.com/reference/crawling/)
  - [Docker](https://zshot-cli.com/reference/docker/)
  - [Exit Codes](https://zshot-cli.com/reference/exit_codes/)
  - [Linux](https://zshot-cli.com/reference/linux/)
  - [LLM Connections](https://zshot-cli.com/reference/llm_connections/)
  - [LLM Formatting](https://zshot-cli.com/reference/llm_formatting/)
  - [Local Inputs](https://zshot-cli.com/reference/inputs/)
  - [Navigator](https://zshot-cli.com/reference/navigator/)
  - [Security](https://zshot-cli.com/reference/security/)
  - **Server**
    - [API](https://zshot-cli.com/reference/server/api/)
    - [Endpoints](https://zshot-cli.com/reference/server/endpoints/)
    - [Metrics](https://zshot-cli.com/reference/server/metrics/)
    - [Additional Assets](https://zshot-cli.com/reference/server/additional-assets/)
    - [Authentication](https://zshot-cli.com/reference/server/authentication/)
    - [Caching](https://zshot-cli.com/reference/server/caching/)
  - [Shell completions](https://zshot-cli.com/reference/shell_completions/)
  - [Storage](https://zshot-cli.com/reference/storage/)
  - [Timeouts](https://zshot-cli.com/reference/timeouts/)
  - [Web Bot Auth](https://zshot-cli.com/reference/web_bot_auth/)
- [Support](https://zshot-cli.com/support/)
- [Changelog](https://zshot-cli.com/changelog/)

Site index: https://zshot-cli.com/llms.txt

