# BugBug AI test recorder

The BugBug Chrome extension records your interactions with a web app and turns them into automated test steps. Three **AI capabilities** run automatically in the background during every recording — no configuration needed.

{% hint style="info" %}
To run or record the tests, you need to install[ **BugBug Chrome extension**](/quick-start/install-test-recorder.md)**.**
{% endhint %}

### Recording overlay

<figure><img src="/files/qII4M02QmWNPvsSkQ26P" alt=""><figcaption><p>BugBug AI test recorder</p></figcaption></figure>

When recording starts, a BugBug panel appears on the right side of the page. By default, BugBug captures all clicks, form inputs, URL navigation, and keyboard typing automatically.

Use the panel buttons to record additional action types:

* [Assertion](/editing-tests/assertions.md) — to check that specific content is visible on the page
* [Hover](/recording-tests-steps/recording-hover.md) — for menus or elements that only appear on mouse-over
* [Use email testing inbox ](https://docs.bugbug.io/editing-tests/variables#user-registration-and-login-using-the-bugbug-testing-inbox) — test signup and login flows with built-in email testing inbox&#x20;
* [Variables](/editing-tests/variables.md)  — for inserting dynamic pieces of text that you can use in your tests
* [Drag & drop](about:blank) — for drag-based interactions

{% hint style="info" %}
Learn more about BugBug [**AI test recorder**](https://bugbug.io/ai-test-recorder/)**.**
{% endhint %}

### What gets recorded automatically

| Action                                 | Recorded automatically?            |
| -------------------------------------- | ---------------------------------- |
| Clicks                                 | Yes                                |
| Keyboard typing                        | Yes                                |
| Form selection (dropdowns, checkboxes) | Yes                                |
| URL navigation                         | Yes                                |
| Hover                                  | Must be added manually via overlay |
| Scroll                                 | Yes                                |
| Drag & drop                            | Must be added manually via overlay |

{% hint style="warning" %}
**Important!** To maintain test independence, BugBug launches each test in a fresh incognito window, ensuring a clean session free of cookies, cache, and local storage.
{% endhint %}

### Recorder's AI capabilities

#### Adaptive Locators

When you click an element, BugBug generates multiple selectors and uses AI to pick the most stable one. It prioritizes data-testid attributes, semantic roles, and visible text — avoiding fragile dynamic IDs or positional CSS that break when the UI changes.

You don't need to write or edit any selectors. BugBug handles it during recording.

{% hint style="info" %}
Learn more about [Selectors](/preventing-failed-tests/selectors.md#adaptive-locators)
{% endhint %}

#### Smart Click & Scroll

BugBug mimics real user behavior instead of dispatching raw JavaScript events. Before each click, it checks whether the element is visible and reachable, retries if it's temporarily covered (e.g. by a cookie banner or animation), and automatically scrolls the page to bring the element into the viewport.

{% hint style="info" %}
Learn more about [Smart click](/preventing-failed-tests/smart-click.md) & [Smart scroll](/preventing-failed-tests/smart-scroll.md)
{% endhint %}

#### Smart Waiting

Before each test step, BugBug checks a series of conditions: Is the page done loading? Is the element visible? Is it finished animating? Is it active (not disabled)?

If the conditions aren't met yet, BugBug waits — so you don't need to add manual delay steps or tune timeouts.

{% hint style="info" %}
Learn more about [Waiting conditions](/preventing-failed-tests/waiting-conditions.md)
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.bugbug.io/recording-tests-steps/bugbug-ai-test-recorder.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
