chrome-cdp

Connect to local Chrome via verified CDP WebSocket endpoints for debugging.

Updated Apr 15, 2026
One-click install
npx skills add https://github.com/AoManoh/project_templates --skill chrome-cdp-aomanoh
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: chrome-cdp
Source: https://github.com/AoManoh/project_templates/tree/main/skills/chrome-cdp
Command: npx skills add https://github.com/AoManoh/project_templates --skill chrome-cdp-aomanoh

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

This Skill prevents “connected but wrong” browser debugging by enforcing stable, verified Chrome DevTools Protocol (CDP) endpoint selection and safe reuse of per-tab daemon sessions when you need to inspect or operate a local browser.

Core Features & Use Cases

  • Verified CDP connection modes: Uses shared-session by default to reuse your already-open headed Chrome profile/window, and only uses isolated-instance when you explicitly ask for a dedicated browser.
  • Per-target attach & stable daemon reuse: Selects the exact target (targetId/windowId/ctx/title/URL/bounds) and keeps commands on the same attached daemon to avoid tab/context drift.
  • Approval-safe handshake behavior: Ensures browser-level and first-page-command CDP approvals are requested sequentially, waits for user action, and stops on timeout rather than continuing with stale daemons.

Quick Start

Ask the AI to connect to your existing local Chrome with CDP to inspect the currently open page and run a small CDP evaluation.

Frequently Asked Questions about chrome-cdp

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I connect to a local Chrome browser using the Chrome DevTools Protocol for debugging?

To connect to a local Chrome browser using the Chrome DevTools Protocol, you use verified CDP WebSocket endpoints with safe shared-session reuse. This allows you to inspect and operate your already-open headed Chrome profile without launching a dedicated browser instance.

What is the best way to select a specific browser tab for CDP inspection without context drift?

The best way to select a specific browser tab for CDP inspection without context drift is by matching precise target identifiers like targetId, windowId, or ctx. This ensures commands remain on the same attached daemon to avoid tab or context switching during automation.

Can I reuse an existing Chrome profile window when running browser automation via CDP?

Yes, you can reuse an existing Chrome profile window when running browser automation via CDP by using the shared-session connection mode. This mode operates on your already-open headed Chrome profile by default, rather than spawning an isolated browser instance.

Why does my CDP browser automation fail on the first page command after connecting?

Your CDP browser automation may fail on the first page command if browser-level and first-page-command approvals are not requested sequentially. The system waits for user action and stops on timeout rather than continuing with stale daemons to ensure a safe handshake.

When do I need an isolated-instance connection mode for Chrome DevTools Protocol?

You need an isolated-instance connection mode for Chrome DevTools Protocol when you explicitly ask for a dedicated browser instance. This mode is used instead of the default shared-session to provide a clean, isolated environment for your specific debugging or automation scenarios.

How do I enumerate browser targets and attach to a specific tab for local inspection?

To enumerate browser targets and attach to a specific tab for local inspection, the system performs browser discovery and target enumeration. It then executes a per-tab attach using stable target matching criteria like targetId, windowId, title, or URL to ensure precise selection.