Navigation Actions
Actions for opening pages and controlling tabs.
open
Go to a URL in the current tab. Waits for the page to load before running the next action.
Value: string (URL)
{ "open": "https://example.com" }
Open a login page before filling credentials:
[
{ "open": "https://example.com/login" },
{ "fill": ["#email", "user@example.com"] },
{ "click": "#submit" }
]
Options
| Option | Type | Default | Description |
|---|---|---|---|
focus | boolean | false | Bring the browser window to the front after navigating |
Bring the window to the front when opening the page:
{
"open": "https://example.com",
"options": { "focus": true }
}
openNewTab
Open a URL in a new tab. All other open tabs are closed unless you disable it.
Value: string (URL)
{ "openNewTab": "https://example.com" }
Options
| Option | Type | Default | Description |
|---|---|---|---|
closeOthers | boolean | true | Close other tabs when opening the new one |
focus | boolean | false | Bring the browser window to the front after opening the tab |
Keep other tabs open:
{
"openNewTab": "https://example.com",
"options": { "closeOthers": false }
}
focus
Bring the browser window to the front. Useful when a task runs in the background and you want the automated window to become visible.
Value: boolean / "true" (truthy to focus; false or "false" is a no-op)
{ "focus": "true" }
Options
| Option | Type | Default | Description |
|---|---|---|---|
windowId | number | active tab's window | Target a specific browser window to focus |
Bringing a window to the front is a request, not a guarantee. The operating system and some Chromium-based browsers (for example Brave) apply focus-stealing prevention and may flash the taskbar/dock instead of raising the window.
setWindowState
Change the browser window state — minimize, maximize, go fullscreen, or restore to normal.
Value: "normal" | "minimized" | "maximized" | "fullscreen"
{ "setWindowState": "maximized" }
Go fullscreen:
{ "setWindowState": "fullscreen" }
Options
| Option | Type | Default | Description |
|---|---|---|---|
windowId | number | active tab's window | Target a specific browser window |
minimized also removes the window from focus — the opposite of focus. Window state cannot be combined with a custom size, so use setViewportSize separately when you need exact dimensions.
setViewportSize
Resize the browser window to a specific width and height. Useful when you need a consistent size for screenshots or testing mobile layouts.
Value: [width, height]
{ "setViewportSize": [1920, 1080] }
wait
Pause for a given number of milliseconds. Use this when a page needs a moment to settle after an action before you continue.
Value: number (milliseconds)
{ "wait": 2000 }
Wait after clicking a button that triggers an animation:
[
{ "click": "#open-modal" },
{ "wait": 500 },
{ "fill": [".modal input", "hello@example.com"] }
]
Prefer waitForElement over wait when possible — it resumes as soon as the element appears rather than waiting a fixed amount of time.