Claude Code with Chrome

Chrome integration lets Claude Code interact with web pages for testing, debugging, and automation tasks that cannot be solved from repository files alone.

Last verified
Applies to
Claude Code 2.1.x. CLI spellings were checked on local version 2.1.198; official docs may describe newer 2.1.x behavior.
Verification method
Chrome setup, site permissions, request confirmation, and limitations were reviewed in official docs; the extension was not installed, connected, or given access to any site.
Official sources
Chrome integrationPermissionsChangelog

Reproducible practice

Reproduce one public-page defect with the smallest Chrome permission scope

Capture URL, visible state, console evidence, and a repeatable path without exposing an authenticated session or submitting data.

Prerequisites

  • A supported Chrome environment and the official extension.
  • A public or disposable test page containing no personal account data.
  • Site permissions limited to the exact test origin.

Steps

  1. Record the test boundary

    Write the exact URL, viewport, expected result, and actions that are allowed before enabling Chrome.

  2. Connect explicitly

    Start Claude Code with Chrome only for this session; connection was not tested in this audit.

    Step 2
    claude --chrome
  3. Reproduce without transmission

    Navigate and inspect visible state and console output; stop before login, form submission, upload, purchase, or permission prompt.

  4. Capture minimal evidence

    Record the final URL, screenshot or console error, and deterministic reproduction steps, then disconnect.

Expected result

The defect is reproduced or ruled out on one permitted origin with no sensitive input, submission, or unrelated browsing access.

Validation

  • Review extension site permissions before and after the test.
  • Repeat the path from a clean page state.
  • Confirm evidence contains no cookie, token, account identifier, or private URL.

Failure handling

Extension cannot connect

Check supported versions and extension state before changing site permissions broadly.

Reproduction requires an account

Use a disposable test account only with explicit authorization; otherwise record the blocker.

Cleanup or rollback

  • Disconnect Chrome and remove the temporary site permission if it is no longer needed.
  • Delete sensitive screenshots or logs through the approved retention process, not ad hoc sharing.

Boundaries and when not to use it

  • Browser access can expose authenticated content and transmit data through clicks or forms; confirmation is required at the action boundary.
  • A public-page reproduction does not prove behavior for another account, region, extension set, or backend state.

What Chrome integration adds

With Chrome connected, Claude Code can inspect pages, read console output, interact with DOM elements, and validate browser behavior while you stay in the terminal or IDE.

Chrome in the full stack

Browser tasks rarely end in the browser alone. Plan the edit, verify, and review path across Chrome, IDE, and repository tests.

Workflows

Define acceptance checks with project test commands after browser validation.

Read guide

Enable Chrome integration

Chrome support is enabled through Claude Code flags and in-session configuration. Verify browser permissions and authentication before debugging prompt behavior.

CommandDescription
claude --chromeStart a session with Chrome browser integration enabled.
/chromeConfigure Claude in Chrome settings inside a session.
claude auth status --textConfirm auth before using browser-connected workflows.
Start a browser-enabled session
claude --chrome "Open the local app, reproduce the login bug, and capture console errors."

Good browser test prompts

Browser tasks need a clear URL, reproduction path, and expected outcome. Ask Claude Code to capture console output and name the acceptance check.

Name the URL

Include local dev URL, route, and account state if relevant.

Require evidence

Ask for console logs, screenshots, or DOM findings before proposing a fix.

Keep scope narrow

Review one user flow at a time to reduce flaky automation.

When to use Chrome vs IDE

Use Chrome integration for live browser behavior. Use IDE integration when inline code edits and visual diffs matter more than page interaction.

Chrome checklist

Related topics