# --browser-pool-max

Source: https://zshot-cli.com/reference/flags/server/browser-pool-max/
Markdown: https://zshot-cli.com/reference/flags/server/browser-pool-max/index.md
Section: [Reference](https://zshot-cli.com/reference/) › [Flags](https://zshot-cli.com/reference/flags/) › [Server](https://zshot-cli.com/reference/flags/server/)
CLI: `--browser-pool-max` · REST: CLI only
Value: `NUMBER` · Default: `1 per 8 CPUs`
License: [Pro](https://zshot-cli.com/support/licenses/pro)

Caps the number of browser processes that [`--cdp`](/reference/flags/server/cdp), [`--server`](/reference/flags/server/server), and `--mcp-local-server` spawn to distribute concurrent load.

| Behavior | Rule |
| --- | --- |
| Scale-out threshold | 8 concurrent `--cdp` clients or renders per process |
| At capacity | New clients and renders route to the least-loaded process |

Each process runs its own main and compositor threads, keeping latency steady under high concurrency while sharing a single license activation. Processes start on demand; if a process exits or stops responding, its active work fails and ZShot spawns a replacement on the next request.

Under `--cdp`, each client stays pinned to one process for the life of its connection and sees only its own pages.

In server mode, pooling activates when [`--server-max-concurrency`](/reference/flags/server/server-max-concurrency) exceeds 8. Concurrency limits, queueing, `/status`, `/metrics`, and `--server-unhealthy-at` apply across the entire pool. On `/metrics`, `zshot_browser_pool_members` reports the active process count, and child processes label their series with `member`.

## Example

Cap a Playwright test run to two browser processes:

**CLI**

```sh
zshot --cdp --browser-pool-max 2 -- npx playwright test
```

Serve 32 concurrent renders across up to four browser processes:

**CLI**

```sh
zshot --server --server-max-concurrency 32 --browser-pool-max 4
```

Disable pooling and run all clients on a single browser process:

**CLI**

```sh
zshot --cdp --browser-pool-max 1 -- npx playwright test
```

## Related

Flags:

- [`--cdp`](https://zshot-cli.com/reference/flags/server/cdp/)
- [`--server`](https://zshot-cli.com/reference/flags/server/server/)
- [`--server-max-concurrency`](https://zshot-cli.com/reference/flags/server/server-max-concurrency/)
- [`--mcp-local-server`](https://zshot-cli.com/reference/flags/agents/mcp-local-server/)

## 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/)
    - [Common](https://zshot-cli.com/reference/flags/common/)
    - [Agents](https://zshot-cli.com/reference/flags/agents/)
    - [Archive](https://zshot-cli.com/reference/flags/archive/)
    - [Browser](https://zshot-cli.com/reference/flags/browser/)
    - [Diagnostics](https://zshot-cli.com/reference/flags/diagnostics/)
    - [Document](https://zshot-cli.com/reference/flags/document/)
    - [Image](https://zshot-cli.com/reference/flags/image/)
    - [Navigator](https://zshot-cli.com/reference/flags/navigator/)
    - [Security](https://zshot-cli.com/reference/flags/security/)
    - [Server](https://zshot-cli.com/reference/flags/server/)
      - **--browser-pool-max**
      - [--cdp](https://zshot-cli.com/reference/flags/server/cdp/)
      - [--cdp-webdriver](https://zshot-cli.com/reference/flags/server/cdp-webdriver/)
      - [--server](https://zshot-cli.com/reference/flags/server/server/)
      - [--server-additional-asset-expiration](https://zshot-cli.com/reference/flags/server/server-additional-asset-expiration/)
      - [--server-basic-auth](https://zshot-cli.com/reference/flags/server/server-basic-auth/)
      - [--server-bind-address](https://zshot-cli.com/reference/flags/server/server-bind-address/)
      - [--server-bind-port](https://zshot-cli.com/reference/flags/server/server-bind-port/)
      - [--server-cache](https://zshot-cli.com/reference/flags/server/server-cache/)
      - [--server-cache-size-limit](https://zshot-cli.com/reference/flags/server/server-cache-size-limit/)
      - [--server-cache-ttl](https://zshot-cli.com/reference/flags/server/server-cache-ttl/)
      - [--server-delegated-auth](https://zshot-cli.com/reference/flags/server/server-delegated-auth/)
      - [--server-delegated-auth-timeout](https://zshot-cli.com/reference/flags/server/server-delegated-auth-timeout/)
      - [--server-enable-cors](https://zshot-cli.com/reference/flags/server/server-enable-cors/)
      - [--server-enable-mcp](https://zshot-cli.com/reference/flags/server/server-enable-mcp/)
      - [--server-enable-prometheus](https://zshot-cli.com/reference/flags/server/server-enable-prometheus/)
      - [--server-enable-schema](https://zshot-cli.com/reference/flags/server/server-enable-schema/)
      - [--server-exit-when-unhealthy](https://zshot-cli.com/reference/flags/server/server-exit-when-unhealthy/)
      - [--server-max-concurrency](https://zshot-cli.com/reference/flags/server/server-max-concurrency/)
      - [--server-prometheus-auth](https://zshot-cli.com/reference/flags/server/server-prometheus-auth/)
      - [--server-prometheus-bind-address](https://zshot-cli.com/reference/flags/server/server-prometheus-bind-address/)
      - [--server-prometheus-bind-port](https://zshot-cli.com/reference/flags/server/server-prometheus-bind-port/)
      - [--server-queue-requests](https://zshot-cli.com/reference/flags/server/server-queue-requests/)
      - [--server-response-header](https://zshot-cli.com/reference/flags/server/server-response-header/)
      - [--server-session-idle-timeout](https://zshot-cli.com/reference/flags/server/server-session-idle-timeout/)
      - [--server-signed-url](https://zshot-cli.com/reference/flags/server/server-signed-url/)
      - [--server-signed-url-max-age](https://zshot-cli.com/reference/flags/server/server-signed-url-max-age/)
      - [--server-token-auth](https://zshot-cli.com/reference/flags/server/server-token-auth/)
      - [--server-unhealthy-at](https://zshot-cli.com/reference/flags/server/server-unhealthy-at/)
      - [--server-update-adblock-interval](https://zshot-cli.com/reference/flags/server/server-update-adblock-interval/)
      - [--server-update-blocklist-interval](https://zshot-cli.com/reference/flags/server/server-update-blocklist-interval/)
    - [Video](https://zshot-cli.com/reference/flags/video/)
  - [Agents](https://zshot-cli.com/reference/agents/)
  - [Configuration](https://zshot-cli.com/reference/configuration/)
  - [Crawling](https://zshot-cli.com/reference/crawling/)
  - [Devices](https://zshot-cli.com/reference/devices/)
  - [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/)
  - [npm](https://zshot-cli.com/reference/npm/)
  - [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](https://zshot-cli.com/reference/server/)
  - [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

