Browser use

Ghostex Browser Use lets coding agents inspect and control embedded CEF browser panes through a stdio MCP server. Agents get Chrome DevTools Protocol access without launching a second browser automation runtime.

MCPCEFDevTools

Requirements

  • Ghostex must be running before the MCP server can attach to CEF.
  • A browser pane does not need to exist yet — create one with ghostex browser open <url>.
  • The Ghostex CLI is bundled with the macOS app and auto-linked on startup.
  • Install the skill: ghostex browser install-skill (or from Settings → Integrations).

MCP configuration

Configure your agent to launch the MCP server over stdio:

[mcp_servers.ghostex-browser]
command = "ghostex"
args = ["browser", "mcp"]

If the CEF remote debugging port is not one of Ghostex's default ports, pass it explicitly or set GHOSTEX_CEF_REMOTE_DEBUGGING_PORT:

args = ["browser", "mcp", "--port", "9333"]

CLI commands

OptionWhat it does
ghostex browser mcpRun the stdio MCP server for CEF DevTools control. Optional --port, --target, --page flags.
ghostex browser install-skillInstall the $ghostex-browser-use skill into ~/agents/skills.
ghostex browser open <url>Open or reuse an embedded browser pane. Defaults to CLI cwd as project path and --reuse similar.
ghostex browser open-paneAlias for browser open.
ghostex browser --help
gx browser open https://example.com --project-path "$PWD"
gx browser open https://docs.ghostex.dev --reuse exact

MCP tools

OptionWhat it does
ghostex_list_pagesList CEF DevTools targets and current page ids.
ghostex_select_pageChoose the target page when multiple panes are open.
ghostex_navigateNavigate the selected CEF page.
ghostex_console_logsRead console messages, Log entries, and exceptions captured after attach.
ghostex_snapshotGet an accessibility-like DOM snapshot with @e element refs.
ghostex_click / ghostex_fillInteract with @e refs or CSS selectors.
ghostex_press_keySend Enter, Tab, Escape, arrows, or printable keys.
ghostex_evaluateRun JavaScript in the selected page for inspection.
ghostex_screenshotCapture a PNG screenshot as base64 MCP image content.

Opening panes

OptionWhat it does
--project-pathScope the pane to a specific project/worktree. Defaults to the CLI process cwd.
--project-idUse when you already know the Ghostex project id from ghostex sessions --json.
--reuse similarDefault. Reuse a same-origin pane in the project instead of creating a duplicate tab.
--reuse exactReuse only when the exact URL matches.
--reuse none / --newForce a separate browser pane.

Keep the returned browser session id and the MCP page id from ghostex_list_pages for follow-up work. Element refs from ghostex_snapshot are only valid for the current page state — re-run after navigation or major DOM changes.

Settings

Related browser settings in Ghostex:

OptionWhat it does
browserFeedbackToolAgentation (default) or React Grab — launched from browser pane context menus for visual feedback.
browserOpenModeAlways browser-pane — browser actions open in embedded CEF panes.
autoSleepBrowserSessionsEnabledOpt-in sleep for inactive browser panes (default idle: 30 minutes).
hideBrowserFaviconUntilHoverHide browser page favicons until a session row is hovered.

Related docs