Browser action

Wait For Element Block

Wait For Element watches a CSS selector and continues only when the target is visible, hidden, attached, or detached.

At a glance

Best for
Dynamic pages
Required setting
CSS selector
Default state
Visible
Error handle
Yes

What it does

Wait For Element gives a page time to reach the state your next Block needs. It is useful after navigation, clicking, typing, or any action that causes content to load.

The Block can wait for an element to appear, disappear, become visible, or become hidden.

Use it when

  • Wait for search results after submitting a search.
  • Wait for a loading indicator to disappear.
  • Wait for a modal or menu before clicking inside it.

Do not use it when

  • You only need a fixed delay; use Wait.
  • The next Block already waits for the same selector.
  • The page state is not tied to a reliable CSS selector.

Settings

Wait For Element requires a selector and supports four target states. The default timeout is 30000ms.

CSS selector

Required: Yes
Variables
Yes
Description
Selector to watch on the current page.

Wait until

Required: No
Variables
No
Description
Choose visible, hidden, attached, or detached. The default is visible.

Timeout

Required: No
Variables
No
Description
Maximum time to wait before the Block fails. The default is 30000ms.

Outputs

Wait For Element does not create a reusable variable. The run output records the selector and wait state.

selectorstring

The selector the Block waited for.

statestring

The expected state used for the wait.

timeoutnumber

The timeout used by the runtime.

Example Flow

Use Wait For Element between the action that changes a page and the Block that needs the new page state.

  1. Open or interact with a page.
  2. Wait for the selector that proves the page is ready.
  3. Run extraction or clicking after the wait succeeds.

Errors and fixes

Start with symptoms visible in the editor or Inspector, then check the earliest Block that produced the wrong page state, variable, or output.

The Block times out.

Check
Confirm the selector exists and the chosen state can happen on the current page.
Fix
Use a more reliable selector or change the target state.

The next Block still runs too early.

Check
Check whether the selector appears before the content is actually ready.
Fix
Wait for a later or more specific element.

Local and cloud runs

Local and cloud runtimes both support visible, hidden, attached, and detached states.