---
title: "Deploy browser-gateway"
description: "Reliable browser infrastructure for AI agents and automation."
category: "Other"
url: https://railway.com/deploy/browser-gateway
---

# Deploy browser-gateway

Reliable browser infrastructure for AI agents and automation.

**[Deploy browser-gateway on Railway](https://railway.com/template/browser-gateway)**

- **Creator:** Ajetunmobi Isaac's Projects
- **Category:** Other
- **Total deploys:** 3

## Template content

### browser-gateway https://browsergateway.com/browser-gateway.svg

- **Image:** ghcr.io/browser-gateway/server:latest
- **Health check:** /health
- **Public domain:** Yes

## Documentation

# Deploy and Host browser-gateway on Railway

Reliable browser infrastructure for AI agents and automation. Route, pool, and failover across any browser provider — Browserless, Steel, Browserbase, local Chrome, anything with a CDP endpoint.

## About Hosting browser-gateway

This template deploys the official, signed multi-arch Docker image (`ghcr.io/browser-gateway/server:latest`) on Railway with a persistent 1 GB volume mounted at `/data` for profile blobs and persistent state.

`BG_TOKEN` (gateway auth) and `BG_ENCRYPTION_KEY` (profile encryption) are auto-generated as 32-character secrets at deploy time, so you never see or manage them by hand. The dashboard becomes available at `/web` immediately after deploy.

## Why Deploy browser-gateway on Railway?

Running browser automation in production usually means stitching together your own provider connections, retries, and state persistence. browser-gateway handles all of it: one connection endpoint, automatic failover, request queuing, encrypted profile storage, and a built-in MCP server for AI agents.

Railway gives you:

- Multi-arch image pulls with zero build time (instant deploy)
- Persistent volume that survives container restarts and image upgrades
- Auto-generated secrets that stay scoped to your service
- HTTPS domain out of the box for the dashboard and WebSocket endpoint

## Common Use Cases

- **AI agents that browse the web** — connect Claude Code, Cursor, browser-use, or any MCP client to the gateway's `/mcp` endpoint
- **Web scraping pipelines** — use the REST API (`/v1/screenshot`, `/v1/content`, `/v1/scrape`) without managing browser pools yourself
- **Session-persistent automation** — log in once, run scripts that resume mid-workflow with cookies and localStorage intact
- **Multi-provider routing** — point the gateway at Browserless, Steel, Browserbase, or any CDP provider; failover happens automatically

## Dependencies for browser-gateway

The gateway is self-contained. The only thing you need to add after deploy is browser providers (the underlying Chrome/Browserless/Steel endpoints to route to). You can add them via the dashboard at `/web/providers` or by editing `gateway.yml` from the Variables tab.

### Deployment Dependencies

- The signed Docker image at `ghcr.io/browser-gateway/server:latest` (publicly accessible)
- A 1 GB Railway volume mounted at `/data` (provisioned by this template)
- `BG_TOKEN` and `BG_ENCRYPTION_KEY` environment variables (auto-generated by this template)

## Documentation

Full docs at https://github.com/browser-gateway/browser-gateway including provider examples, REST API reference, MCP integration guides, and the profile encryption model.


## Similar templates

- [Rocky Linux](https://railway.com/deploy/rocky-linux) — Hosted Rocky Linux 9 workspace with SSH and persistent storage. 🚀
- [Foundry Virtual Tabletop](https://railway.com/deploy/X5tR6G) — A Self-Hosted & Modern Roleplaying Platform
- [Letta Code Remote](https://railway.com/deploy/letta-code-remote) — Run a Letta Code agent 24/7. No inbound ports, just deploy.

Open this page in a browser: https://railway.com/deploy/browser-gateway
