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

> ## Agent Instructions
> The canonical docs host is https://momentic.ai/docs. Append .md to any page URL for clean Markdown. Fetch https://momentic.ai/docs/llms.txt for the page index and https://momentic.ai/docs/llms-full.txt for every page in one file.
> For an unattended setup, first check whether Claude Code already has the Momentic plugin. With the plugin, run `npx --yes @momentic/wizard@latest -y --platform web --editor-tools none` and ignore any CLI skills-install suggestion in its output. Otherwise, run `npx --yes @momentic/wizard@latest -y --platform web --editor-tools skills`. Use `--platform ios` or `--platform android` for mobile. Never run an interactive command in a non-TTY shell.
> Mo is the AI QA engineer, separate from repository YAML tests. For shell-capable coding agents, recommend the CLI-only `mo-qa` skill by default. Use `qa skills --target <agent>` with the current agent's target. For a no-global setup, use `npx -y qa skills --target <agent>` and see the [Mo Quickstart](https://momentic.ai/docs/mo/quickstart.md). Use hosted MCP by default for clients that cannot execute commands. Honor the user's requested interface and any existing `mo-qa` skill/plugin distribution: do not overwrite it or co-install CLI-only and MCP-only copies for one workflow; ask before switching an existing setup. When hosted MCP is requested or required by the client, use it for web or mobile targets. For private targets, hosted sessions require an online Connector and use its listed name as `access`. If none is online, ask the user to run `npx -y qa tunnel start --name <name> <address>` on a machine that reaches the target and wait for it to appear in the organization's online Connectors. Then rediscover the Connector and pass its listed name as `access`; that name may equal the CLI tunnel ID. If required hosted tools or authentication are unavailable, report the blocker. Never switch a requested hosted session to CLI. Use the `qa` CLI for sessions that need a new tunnel. If you cannot run tunnel commands on the machine that reaches the target, ask the user to start the tunnel there and wait; do not run login or tunnel commands for them. For a CLI agent that explicitly requests hosted MCP, the optional `momentic-hosted` stdio bridge running `npx -y qa mcp` requires a valid saved CLI sign-in for the same machine, OS user, and server; it reuses a valid sign-in without another login, and `MOMENTIC_API_KEY` alone cannot authenticate the bridge. If no valid matching sign-in exists or the bridge reports sign-in is required, ask the user to run `npx -y qa login --server <server>` for the bridge's server, then restart the bridge and reconnect the MCP client before retrying. The Mo credential guidance below applies to regular `qa` CLI sessions, not bridge authentication. Plugin users must explicitly opt in and disable their hosted plugin entry before adding the bridge. Claude.ai and ChatGPT connectors use `https://mcp.momentic.ai` with OAuth. After hosted testing completes, read the report and summarize findings and uncovered requirements. Call `momentic_mo_stop_session` only when the user asks or agrees. For CLI sessions, unless the user wants more testing, export the report, run `qa stop <id> --subagents` even if export fails, then summarize. The CLI is `qa`, not `mo`.
> For repository-test CLI tools, `MOMENTIC_API_KEY` takes precedence over the API key saved in `~/.momentic/auth.json`; when the environment variable is absent, the CLI reuses the saved key. If an environment key is rejected, ask the user to replace or unset it before retrying. When a valid saved key exists, unsetting the environment variable lets the CLI reuse it. If neither a valid environment key nor saved key is available, ask the user to complete browser sign-in or create a key at https://app.momentic.ai/settings/api-keys and set it as `MOMENTIC_API_KEY` in the agent's environment. For regular Mo commands through the `qa` CLI (not the optional `qa mcp` bridge), follow the [Quickstart authentication steps](https://momentic.ai/docs/mo/quickstart.md#setup-with-coding-agent) to verify the active credential. Do not request another credential while the active credential is valid. `MOMENTIC_API_KEY` overrides a saved login. If the environment key is rejected, report that it was rejected by the selected server. Confirm the intended API server with the user if needed and recheck against it using the explicit `--server <server>` option. Only if it is rejected there should you ask the user to replace or unset it; after unsetting, reuse a valid saved login instead of requesting another credential. Do not retry `qa login` alone. Never print the key or ask the user to paste it into chat.
> Momentic's capability summary for agents is at https://momentic.ai/docs/skill.md. Claude Code users with the Momentic plugin should use its bundled skills and skip CLI skills installation. Otherwise, run `npx momentic skills -y --target <agent>` or `npx momentic-mobile skills -y --target <agent>`. Both install momentic-test, momentic-maintain, and momentic-spec with web/mobile references. Use the running agent's target. The Momentic plugin also includes mo-qa; qa skills installs only mo-qa.
> Tests are YAML files in the user's repository. Use only the step names listed at https://momentic.ai/docs/reference/commands.md and the file structure at https://momentic.ai/docs/core-concepts/file-format.md. Do not invent step names, config keys, or CLI flags.
> Web tests run on Chromium, iOS tests on simulators, and Android tests on emulators.

# Chrome extensions

> Load an unpacked Chrome extension in local Chromium tests.

Load a Chrome extension before your test starts to verify how it changes your
app. Use an unpacked extension with a locally launched Chromium browser, on your
machine or on a continuous integration (CI) runner.

> [!WARNING]
>
> Extensions aren't supported on Momentic-hosted browsers or the cloud
> dashboard. Use **Chromium**. Google Chrome 137 and later no longer support the
> extension-loading mechanism Momentic uses, and Momentic doesn't support
> loading extensions in **Chrome for Testing**.

## Configure your project

Start with an existing [Momentic project](https://momentic.ai/docs/quickstart/web.md) and a test you want
to run with the extension.

**1. Prepare the extension**

Build or extract the extension into a directory on the machine running
Momentic. An unpacked extension is a folder containing `manifest.json` and
the extension's scripts and assets. Point Momentic at that folder, not a
Chrome Web Store URL, extension ID, or packed `.crx` file.

For example, place the extension in `extensions/checkout-helper/` at your
project root. Check that `extensions/checkout-helper/manifest.json` exists
before continuing.

**2. Set the browser and extension path**

Add these settings to your existing `momentic.config.yaml`:

```yaml momentic.config.yaml theme={null}
browser:
  defaultBrowserType: Chromium
  remoteBrowser: false
  localChromeExtensionPaths:
    - ./extensions/checkout-helper
```

Relative extension paths resolve from the directory where you launch
Momentic. Run the commands below from your project root, or use an absolute
path. Add another list entry for each additional extension.

[Environment settings](https://momentic.ai/docs/configuration/environments.md) and per-test settings
can override these defaults. Check that your test still uses `Chromium`
and `remoteBrowser: false`. Don't pass `--remote-browser-region`, which
enables hosted browsers for the run.

**3. Run the test**

Install the Chromium build for your Momentic version:

```bash theme={null}
npx momentic install-browsers chromium
```

Run an existing test with the extension. Replace the path with your test's
path:

```bash theme={null}
npx momentic run tests/checkout.test.yaml
```

Momentic loads the extension before the test starts. Assert on the
extension's effect in your app, such as an injected element or a change to
the page's appearance.

## Configure one test in the local editor

To set extension paths for one test instead of the whole project, open the local
editor from your project root:

```bash theme={null}
npx momentic app
```

1. Open the test's **Test options** and select the **Browser** tab.
2. Set **Browser type** to **Chromium**.
3. Enter the unpacked extension directory in **Load Chrome extension**. Use
   comma-separated paths to load multiple extensions.
4. Save the settings. The editor reloads the browser session with the extension.

## Run in CI

Make the unpacked extension available on the CI runner before `momentic run`. If
you build the extension in CI, finish the build first. Keep the same directory
layout and run Momentic from the same project directory as you do locally. An
absolute path on your laptop won't exist on the runner.

Install Chromium on the runner and keep `remoteBrowser: false`. Your existing
[CI configuration](https://momentic.ai/docs/running-tests/ci/github-actions.md) otherwise runs the test the
same way.

## Troubleshooting

* If Momentic reports that an extension path doesn't exist, check for
  `manifest.json` directly inside the configured directory. Check the directory
  where you launched Momentic when using a relative path.
* If Momentic rejects a hosted browser connection, check the project,
  environment, and test settings for `remoteBrowser: true`. Remove any
  `--remote-browser-region` flag from the run command.
* If the extension doesn't affect the page, confirm that the test uses Chromium
  and that the extension's manifest matches your app's URL.

See
[browser configuration](https://momentic.ai/docs/configuration/browser.md#browser-localchromeextensionpaths)
for the setting reference and [supported browsers](https://momentic.ai/docs/platforms/web/browsers.md) for
the browser options.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.