n8n-io/n8n · error · BrowserNotAvailableError
Browser not available: ${browser}
Error message
Browser not available: ${browser} What it means
BrowserNotAvailableError is thrown by requireBrowserAvailable when the requested browser's info is missing or marked unavailable in the config map. The error message names the browser and the hint lists compatible Chromium-based alternatives plus install instructions. This runs in connect() for non-remote modes before any adapter is created.
Source
Thrown at packages/@n8n/mcp-browser/src/connection.ts:202
return this.config;
}
// -------------------------------------------------------------------------
// Private
// -------------------------------------------------------------------------
getAvailableBrowsers(): BrowserName[] {
return [...this.config.browsers.entries()]
.filter(([_, v]) => v.available)
.map(([name]) => name);
}
private requireBrowserAvailable(browser: BrowserName): void {
const info = this.config.browsers.get(browser);
if (!info?.available) {
const available = this.getAvailableBrowsers();
const instructions = getInstallInstructions(browser);
throw new BrowserNotAvailableError(browser, available, instructions);
}
}
private async createAdapter(): Promise<Adapter> {
if (this.config.mode === 'remote') {
// Remote mode is only supported by the Playwright adapter
const { PlaywrightAdapter } = await import('./adapters/playwright.js');
return new PlaywrightAdapter(this.config, {
relay: this.externalRelay,
cdpEndpoint: this.externalCdpEndpoint,
cdpConnectHeaders: this.cdpConnectHeaders,
});
}
if (this.config.adapter === 'agent-browser') {
const { AgentBrowserAdapter } = await import('./adapters/agent-browser.js');
return new AgentBrowserAdapter(this.config);
}
const { PlaywrightAdapter } = await import('./adapters/playwright.js');View on GitHub (pinned to 5ac6606e81)
Solutions
- Install a compatible Chromium-based browser (Chrome, Brave, Edge, or Chromium).
- Call browser_connect with one of the browsers listed in the error's hint (availableBrowsers).
- Provide an explicit executablePath in the config for a non-standard install location.
- For servers, use remote mode (config.mode='remote') with an external CDP endpoint.
Example fix
// before — requested browser not installed
await connection.connect('firefox'); // throws BrowserNotAvailableError
// after — use an available browser or remote mode
const avail = connection.getAvailableBrowsers();
await connection.connect(avail[0]);
// or: config.mode = 'remote' with externalCdpEndpoint Defensive patterns
Strategy: validation
Validate before calling
const available = connection.getAvailableBrowsers();
if (!available.includes(browser)) {
browser = available[0]; // or throw with install instructions
} Type guard
function browserAvailable(c: BrowserConnection, name: BrowserName): boolean {
return c.getAvailableBrowsers().includes(name);
} Prevention
- Call getAvailableBrowsers() and pick from the returned list.
- For servers, use remote mode with an external CDP endpoint.
- Provide explicit executablePath for non-standard browser installs.
When it happens
Trigger: Calling browser_connect with a browser name that discovery did not flag as available (no executable path, not installed, or unsupported). Also when defaultBrowser points at a browser that was uninstalled since discovery ran.
Common situations: Chrome/Brave/Edge/Chromium not installed on the host. Browser installed but not in a standard location and executablePath not configured. Wrong browser name string passed (case mismatch, typo). Headless server with no browser binaries.
Related errors
- Reflector output did not contain a JSON object
- MCP server "${cfg.name}": exactly one of "url" or "command"
- MCP server "${cfg.name}": provide either "url" or "command",
- MCP server name "${cfg.name}" is already registered
- Azure Blob container name not configured. Please set `N8N_EX
AI-assisted analysis of n8n-io/n8n@5ac6606e81 (2026-08-12).
Data as JSON: /api/errors/84d6ff464065ff96.
Report an issue: GitHub.