Skip to main content
Cloud Browser starts a browser synchronously and returns a signed WebSocket URL. Connect with Playwright or Puppeteer, navigate to the site you need, and stop the session when the job is complete.
Creating a session starts a browser resource. Treat connectUrl, liveViewUrl, API keys, cookie values, and proxy credentials as secrets. Use placeholders in logs and support messages.

Before You Start

Create or copy a Client API key from API keys, then set local environment variables.

1. Create a Session

Every request field is optional. Start with {} to use a coherent Linux fingerprint, a residential proxy with sticky rotation, a 600-second timeout, and keepAlive: false.
The response contains:
  • id: the browser session ID
  • connectUrl: a signed WebSocket URL for the active session
  • settings.id: an opaque ID for restoring saved identity and browser state
  • runtime: the effective timeout and reconnect behavior
  • lifecycle timestamps including expiresAt
Store the session ID and settings ID. Do not construct or persist the signed connection URL; get the active session again when you need a fresh one. For a local test, provide the returned connectUrl as FLOPPY_CONNECT_URL in the process environment. Keep it out of source control and shell history.

2. Connect and Navigate

Cloud Browser does not accept startUrl. Connect first, then navigate with your automation client.

Playwright

Puppeteer

The relay permits one active connection per session. Its heartbeat is handled by Floppydata; your client does not need to send a custom keepalive command.

3. Stop the Session

Explicitly stop the session after the job. The operation is idempotent and synchronizes saved browser state.
With the default keepAlive: false, closing the relay also stops the session. With keepAlive: true, disconnecting releases the connection so you can reconnect until expiresAt; call stop when the job is finished.

Customize a New Browser

Send only the groups you need. This example sets viewport and fingerprint preferences, targets a US residential proxy, extends the runtime, and attaches caller-owned metadata.
For interval rotation, use mode: "interval" with intervalMinutes set to 5, 10, 15, 20, or 60. Use mode: "perRequest" for a new proxy IP per request, or mode: "sticky" with an optional caller-defined stickyKey.

Import Cookies Before Launch

Cookie values are write-only. Import at most 100 cookies and provide exactly one of url or domain for each item.
Cookie mode defaults to merge. Use replace only when you intend to clear the saved cookies first. Never put real cookie values in documentation, logs, or support messages.

Reuse Saved Settings

Reuse settings.id to restore the same saved identity and browser state.
You cannot combine settings.id with browser or proxy; that prevents accidental identity mutation. You can still send cookies, runtime options, and metadata. One active session can use a settings ID at a time. Each account can keep up to 20 saved settings. Session history includes settings.id, so you can recover an ID without a separate settings-list endpoint.

Inspect Sessions and Reconnect

Get one session to check its state and receive a freshly signed connectUrl while it is active.
List history with optional status filtering and cursor pagination.
Pass nextCursor back unchanged to load the next page. Session states are running, stopped, timedOut, and failed.

Open a Live View

Close any active Playwright or Puppeteer connection first, then request a fresh live-view URL.
Open liveViewUrl in a browser. Treat it as a temporary secret and do not log or share it.

Delete Saved Settings

Deletion permanently removes saved browser identity and state. It cannot be undone.
Stop any active session first, then delete the settings.
The API returns 204 when deletion succeeds. It returns settings_in_use instead of silently stopping an active session.

Errors and Recovery

Operational Limits

  • Incoming WebSocket messages are limited to approximately 1 MiB. Very large CDP payloads, such as full-page screenshots or screencast frames, can close the relay.
  • A Worker deployment can drop a live relay. With keepAlive: true, get the session again and reconnect with the fresh connectUrl before expiresAt.
  • A signed connection URL admits one active relay and expires with its session.

Create a Session

Inspect every request field and response property.

List Sessions

Filter history and paginate with an opaque cursor.

API Conventions

Review authentication, errors, and WebSocket behavior.