> ## Documentation Index
> Fetch the complete documentation index at: https://docs.bringits.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Browser Open

> Open a browser session and navigate to a URL

The Browser Open command enables you to open a browser session and navigate to a URL. This command is essential for initiating browser-based workflows and establishing browser sessions for subsequent browser commands.

## Overview

The Browser Open command provides functionality for:

* Opening browser sessions (Chrome, Firefox, etc.)
* Navigating to URLs
* Managing browser session state
* Configuring browser options
* Establishing persistent sessions across commands

## Parameters

| Parameter       | Type   | Description                                | Required |
| --------------- | ------ | ------------------------------------------ | -------- |
| **sessionId**   | string | Session identifier for maintaining state   | No       |
| **url**         | string | URL to navigate to                         | Yes      |
| **browserType** | string | Browser type (chrome, firefox, etc.)       | No       |
| **timeout**     | number | Maximum wait time in milliseconds          | No       |
| **options**     | object | Browser options (headless, viewport, etc.) | No       |

## Usage Examples

### Basic Browser Open

```json theme={null}
{
  "command": "browser-open",
  "params": {
    "url": "https://example.com"
  }
}
```

### Browser Open with Session

```json theme={null}
{
  "command": "browser-open",
  "params": {
    "sessionId": "#{UUID}",
    "url": "https://example.com"
  }
}
```

### Browser Open with Options

```json theme={null}
{
  "command": "browser-open",
  "params": {
    "url": "https://example.com",
    "browserType": "chrome",
    "options": {
      "headless": false,
      "viewport": {
        "width": 1920,
        "height": 1080
      }
    },
    "timeout": 30000
  }
}
```

### Browser Open with Dynamic URL

```json theme={null}
{
  "command": "browser-open",
  "params": {
    "url": "https://example.com/page?id=@{PROJECT_ID}",
    "sessionId": "#{UUID}"
  }
}
```

## Session Management

The Browser Open command supports session management for maintaining state across commands:

### Creating a Session

```json theme={null}
{
  "command": "browser-open",
  "params": {
    "sessionId": "#{UUID}",
    "url": "https://example.com"
  }
}
```

### Reusing a Session

Subsequent commands can use the same session ID:

```json theme={null}
{
  "command": "click",
  "params": {
    "sessionId": "#{UUID}",
    "selector": ".button"
  }
}
```

## Variable Support

The Browser Open command supports variable interpolation in:

* **URL**: Use `@{VARIABLE}` in URLs
* **Session ID**: Use `#{UUID}` for session tracking

### Common Variable Patterns

* **Project Variables**: `@{PROJECT_ID}`, `@{RUN_ID}` - Include in URLs
* **Session Variables**: `#{UUID}` - Maintain browser session state
* **Dynamic URLs**: Use variables to construct dynamic URLs

## Browser Options

Configure browser behavior with options:

### Common Options

* **headless**: Run browser in headless mode (default: false)
* **viewport**: Set browser viewport size
* **userAgent**: Set custom user agent string
* **timeout**: Set navigation timeout

## Best Practices

* **Use Session IDs**: Leverage `#{UUID}` for maintaining browser state
* **Set Appropriate Timeouts**: Configure timeouts for page loading
* **Handle Navigation Errors**: Implement error handling for failed navigation
* **Use HTTPS**: Prefer HTTPS URLs for secure connections
* **Configure Viewport**: Set appropriate viewport size for consistent rendering

## Common Use Cases

* **Web Scraping**: Open pages for content extraction
* **Form Automation**: Navigate to forms for automation
* **Multi-Page Workflows**: Establish sessions for multi-page navigation
* **Dynamic Content**: Handle JavaScript-rendered content

## Related Commands

* [Get Text Contents](/stream/commands/browser/get-text-contents) - Extract text after opening browser
* [Get Attributes](/stream/commands/browser/get-attributes) - Extract attributes after opening browser
* [Interaction Commands](/stream/commands/interaction) - Interact with opened pages
