Skip to content

/connect Endpoint

The /connect endpoint is the simplest way to use rayobrowse. Connect any CDP client to a single URL — a browser is auto-created on connection and cleaned up when you disconnect.

ws://localhost:9222/connect?headless=true&os=windows

No SDK needed. Any CDP-capable tool (Playwright, Puppeteer, Selenium, OpenClaw, Scrapy) can connect directly.

# pip install playwright && playwright install
from playwright.sync_api import sync_playwright
with sync_playwright() as p:
browser = p.chromium.connect_over_cdp(
"ws://localhost:9222/connect?headless=true&os=windows"
)
page = browser.new_context().new_page()
page.goto("https://example.com")
print(page.title())
browser.close()
ParameterDefaultDescription
headlesstruetrue or false
oslinuxFingerprint OS: windows, linux, android, macos
browser_namechromeBrowser fingerprint type
browser_version_min(latest)Minimum Chrome version
browser_version_max(latest)Maximum Chrome version
proxy(none)Proxy URL, e.g. http://user:pass@host:port
browser_language(auto)Accept-Language value
ui_language(auto)Browser UI locale
screen_width_min(auto)Minimum screen width
screen_height_min(auto)Minimum screen height
api_key(none)Required in remote mode
ws://localhost:9222/connect?headless=true&os=windows&proxy=http://user:pass@host:port
ws://localhost:9222/connect?headless=false&os=windows

View at http://localhost:6080/vnc.html.

ws://localhost:9222/connect?headless=true&os=windows&browser_version_min=146&browser_version_max=146
  1. Created when a CDP client connects to the /connect WebSocket
  2. Active while the WebSocket connection is alive
  3. Cleaned up automatically after the connection closes (2-second grace period)

Each connection gets a fresh browser instance with a new fingerprint profile.