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

# Proxies

> Route a hosted browser session through your SOCKS5 proxy.

Pass `proxyUrl` when you need browser traffic to use your own SOCKS5 proxy.

## Use a Proxy

<CodeGroup>
  ```typescript TypeScript theme={null}
  const session = await client.browser.session.create({
    type: "hosted",
    proxyUrl: "socks5://user:pass@proxy.example.com:1080",
  });
  ```

  ```python Python theme={null}
  resp = requests.post(
      "https://api.driver.dev/v1/browser/session",
      headers={
          "Authorization": f"Bearer {os.getenv('DRIVER_API_KEY')}",
          "Content-Type": "application/json",
      },
      json={
          "type": "hosted",
          "proxyUrl": "socks5://user:pass@proxy.example.com:1080",
      },
  )
  resp.raise_for_status()
  session = resp.json()
  ```

  ```bash cURL theme={null}
  curl -X POST https://api.driver.dev/v1/browser/session \
    -H "Authorization: Bearer $DRIVER_API_KEY" \
    -H "Content-Type: application/json" \
    -d '{"type":"hosted","proxyUrl":"socks5://user:pass@proxy.example.com:1080"}'
  ```
</CodeGroup>

## Format

```text theme={null}
socks5://username:password@host:port
```

<Warning>
  `proxyUrl` must point to a real SOCKS5 proxy reachable from Driver infrastructure. It cannot be used with `nodeId`.
</Warning>
