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

> ## Agent Instructions
> Anchor Browser is cloud browser infrastructure for AI agents and automation: browser sessions you control over CDP or REST, natural-language web tasks, versioned automation tasks, managed authentication into third-party web apps (identities with MFA), persistent volumes and profiles, recordings, live view, batch sessions, webhooks, and network options including residential proxies, extra stealth, and captcha solving for sites that block standard browsers. AI agents should start at https://docs.anchorbrowser.io/for-agents, then create an API key at https://app.anchorbrowser.io/api-keys. Read the for-agents page before authentication or API calls.

# On-premise deployment

> Deploy Anchor Browser on your own infrastructure with flexible hosting options

Anchor Browser supports on-premise deployment for organizations that require full control over their browser infrastructure. Choose from three deployment options based on your security, compliance, and operational requirements.

## Deployment options

> [card] Self-hosted
>
> Full Anchor deployment on your AWS infrastructure

> [card] Containerized
>
> Deploy on your end customer's premise

> [card] Browser container only
>
> Run Anchor's browser container on your own infrastructure

***

## Option 1: Self-hosted on your premise

Deploy the complete Anchor Browser platform on your own AWS infrastructure using CloudFormation or role-based access.

### What gets deployed

The deployment provisions the following resources in your AWS account:

* **EKS cluster** — Manages browser container orchestration and scaling
* **Database instance** — Stores task definitions, session metadata, and configuration
* **S3 bucket** — Handles file storage for session recordings and artifacts
* **Secrets Manager** — Securely stores credentials and API keys

### Deployment methods

> [tab] AWS CloudFormation
>
> Deploy using a CloudFormation template that provisions all required resources automatically.
>
> ```bash theme={null}
> aws cloudformation create-stack \
>   --stack-name anchor-browser \
>   --template-url https://anchor-deployments.s3.amazonaws.com/cloudformation/latest.yaml \
>   --parameters \
>     ParameterKey=Environment,ParameterValue=production \
>     ParameterKey=ClusterSize,ParameterValue=3 \
>   --capabilities CAPABILITY_IAM
> ```

> [tab] Role-based access
>
> Grant Anchor deployment access through an IAM role, allowing the Anchor team to manage the initial setup while you retain full control of the infrastructure.
>
> ```bash theme={null}
> aws iam create-role \
>   --role-name AnchorDeploymentRole \
>   --assume-role-policy-document file://anchor-trust-policy.json
> ```
>
> ```bash theme={null}
> aws iam attach-role-policy \
>   --role-name AnchorDeploymentRole \
>   --policy-arn arn:aws:iam::policy/AnchorDeploymentPolicy
> ```

### SDK usage

Once deployed, point your SDK to the on-premise endpoint:

```python python theme={null}
import os
from anchorbrowser import Anchorbrowser

client = Anchorbrowser(
    api_key=os.getenv("ANCHOR_API_KEY"),
    base_url="https://anchor.internal.yourcompany.com"
)

session = client.sessions.create_session()
print(f"Session started: {session.data.id}")
```

```javascript node.js theme={null}
import { client, Sessions } from "anchorbrowser";

client.setConfig({
  auth: () => process.env.ANCHOR_API_KEY,
  baseUrl: "https://anchor.internal.yourcompany.com",
});

const session = await Sessions.createSession();
console.log(`Session started: ${session.data.id}`);
```

***

## Option 2: Containerized deployment on your end customer's premise

Deploy the full Anchor Browser platform on your end customer's infrastructure. This option uses the same deployment method as Option 1 — AWS CloudFormation or role-based access — but targets your customer's AWS account.

### What gets deployed

Identical to Option 1, the deployment creates:

* **EKS cluster** for browser orchestration
* **Database instance** for metadata and configuration
* **S3 bucket** for file storage
* **Secrets Manager** for credential management

### How it works

**1. Prepare the customer environment**

Ensure the customer's AWS account meets the minimum requirements (VPC, subnets, IAM permissions).

**2. Deploy via CloudFormation or role-based access**

Use either deployment method to provision resources in the customer's account.

```bash theme={null}
aws cloudformation create-stack \
  --stack-name anchor-browser-customer \
  --template-url https://anchor-deployments.s3.amazonaws.com/cloudformation/latest.yaml \
  --parameters \
    ParameterKey=Environment,ParameterValue=production \
    ParameterKey=ClusterSize,ParameterValue=3 \
    ParameterKey=TenantId,ParameterValue=customer-abc \
  --capabilities CAPABILITY_IAM
```

**3. Configure network access**

Set up VPC peering or private endpoints to connect your application layer to the customer's Anchor deployment.

**4. Validate the deployment**

Verify the deployment is operational using the health check endpoint.

```bash theme={null}
curl https://anchor.customer-abc.internal/health
```

***

## Option 3: Browser container only

Deploy Anchor's browser container on infrastructure you manage, while keeping the management layer separate. This is the most flexible option — you control where and how browser sessions run.

> [!NOTE]
>
> With this option, the Anchor management plane is not deployed on your infrastructure. You define browser tasks using custom scripts or direct requests to the browser's agent.

### Use cases

* You have existing orchestration infrastructure and want to add Anchor's browser capabilities
* You need to deploy browser containers on non-AWS infrastructure
* You want to run browser tasks on a customer's premise without deploying the full platform

### Task definition methods

Choose how you define and execute browser tasks:

> [accordion] Custom Playwright scripts
>
> Write Playwright scripts that connect to the Anchor browser container directly.
>
> ```python python theme={null}
> from playwright.sync_api import sync_playwright
>
> with sync_playwright() as p:
>     browser = p.chromium.connect_over_cdp(
>         "ws://anchor-browser.internal:9222"
>     )
>     page = browser.new_page()
>     page.goto("https://example.com")
>
>     # Perform your automation
>     page.fill("#username", "user@example.com")
>     page.click("button[type='submit']")
>
>     result = page.text_content(".dashboard-summary")
>     print(f"Result: {result}")
>
>     browser.close()
> ```
>
> ```javascript node.js theme={null}
> import { chromium } from "playwright";
>
> const browser = await chromium.connectOverCDP(
>   "ws://anchor-browser.internal:9222"
> );
> const page = await browser.newPage();
> await page.goto("https://example.com");
>
> // Perform your automation
> await page.fill("#username", "user@example.com");
> await page.click("button[type='submit']");
>
> const result = await page.textContent(".dashboard-summary");
> console.log(`Result: ${result}`);
>
> await browser.close();
> ```

> [accordion] Direct requests to the browser agent
>
> Send task instructions directly to the Anchor browser agent via its API.
>
> ```python python theme={null}
> import requests
>
> response = requests.post(
>     "http://anchor-browser.internal:8080/agent/task",
>     json={
>         "instruction": "Navigate to example.com and extract the pricing table",
>         "output_format": "json"
>     }
> )
>
> result = response.json()
> print(f"Task result: {result['data']}")
> ```
>
> ```javascript node.js theme={null}
> const response = await fetch(
>   "http://anchor-browser.internal:8080/agent/task",
>   {
>     method: "POST",
>     headers: { "Content-Type": "application/json" },
>     body: JSON.stringify({
>       instruction:
>         "Navigate to example.com and extract the pricing table",
>       outputFormat: "json",
>     }),
>   }
> );
>
> const result = await response.json();
> console.log(`Task result: ${result.data}`);
> ```

> [accordion] Built on Anchor, deployed manually
>
> Build and test your automation on the Anchor platform, then export and deploy the task to the customer's premise.
>
> ```python python theme={null}
> from anchorbrowser import Anchorbrowser
> import os
>
> # Build and test on Anchor platform
> client = Anchorbrowser(api_key=os.getenv("ANCHOR_API_KEY"))
>
> # Export the task for on-premise deployment
> task = client.tasks.get("task_abc123")
> task_bundle = client.tasks.export(
>     task_id=task.id,
>     version="latest",
>     format="container"
> )
>
> # Deploy the exported bundle to customer infrastructure
> print(f"Bundle ready: {task_bundle.artifact_url}")
> ```
>
> ```javascript node.js theme={null}
> import { client } from "anchorbrowser";
>
> // Build and test on Anchor platform
> client.setConfig({ auth: () => process.env.ANCHOR_API_KEY });
>
> // Export the task for on-premise deployment
> const { data: task } = await client.get({ url: "/v2/tasks/task_abc123" });
> const { data: taskBundle } = await client.post({
>   url: `/v2/tasks/${task.id}/export`,
>   body: {
>     version: "latest",
>     format: "container",
>   },
> });
>
> // Deploy the exported bundle to customer infrastructure
> console.log(`Bundle ready: ${taskBundle.artifactUrl}`);
> ```

### Container deployment

Deploy the Anchor browser container using Docker or Kubernetes:

> [tab] Docker
>
> ```bash theme={null}
> docker run -d \
>   --name anchor-browser \
>   -p 9222:9222 \
>   -p 8080:8080 \
>   -e ANCHOR_LICENSE_KEY=$ANCHOR_LICENSE_KEY \
>   anchor/browser:latest
> ```

> [tab] Kubernetes
>
> ```yaml deployment.yaml theme={null}
> apiVersion: apps/v1
> kind: Deployment
> metadata:
>   name: anchor-browser
> spec:
>   replicas: 3
>   selector:
>     matchLabels:
>       app: anchor-browser
>   template:
>     metadata:
>       labels:
>         app: anchor-browser
>     spec:
>       containers:
>         - name: browser
>           image: anchor/browser:latest
>           ports:
>             - containerPort: 9222
>             - containerPort: 8080
>           env:
>             - name: ANCHOR_LICENSE_KEY
>               valueFrom:
>                 secretKeyRef:
>                   name: anchor-secrets
>                   key: license-key
> ```

***

## Comparison

| Feature | Self-hosted | Containerized | Browser container only |
| - | - | - | - |
| **Full Anchor platform** | Yes | Yes | No |
| **Management dashboard** | Yes | Yes | No |
| **Task API** | Yes | Yes | No |
| **Custom Playwright scripts** | Yes | Yes | Yes |
| **Browser agent API** | Yes | Yes | Yes |
| **Infrastructure** | Your AWS account | Customer's AWS account | Any infrastructure |
| **Setup complexity** | Low | Medium | Low |

## Get started

Contact the Anchor team at [support@anchorbrowser.io](mailto:support@anchorbrowser.io) to discuss which deployment option fits your requirements and to receive access to deployment templates.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.