agent-browser

Automates browser tasks via a command-line interface with CDP-first connections and persistent sessions.

Updated Aug 23, 2026
One-click install
npx skills add https://github.com/hammercui/openclaw-install-cn --skill agent-browser-hammercui
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: agent-browser
Source: https://github.com/hammercui/openclaw-install-cn/tree/main/04-%E9%AB%98%E7%BA%A7%E9%85%8D%E7%BD%AE/skills-cn/agent-browser
Command: npx skills add https://github.com/hammercui/openclaw-install-cn --skill agent-browser-hammercui

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Streamlines browser automation for AI agents by ensuring a CDP-first connection and a persistent user-data-dir so sessions can be reused across tasks.

Core Features & Use Cases

  • CDP-first connection to preserve login state and reuse sessions across automation runs.
  • Persistent profile guidance to keep login context between tasks.
  • Tab management rules: different URLs open in new tabs; same URL pages reuse the current tab with careful navigation.
  • Flexible CLI workflow with auto-connect and explicit CDP options to cover both existing and new browser scenarios.
  • Real-world Use Case: automate a sequence of AI agent tasks across multiple sites while maintaining login state and session continuity.

Quick Start

Connect to an existing CDP-enabled browser with the auto-connect option and begin automating tasks on a target URL.

Frequently Asked Questions about agent-browser

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

FAQPage Schema
How do I maintain login state for browser automation across multiple AI agent tasks?

Browser automation can maintain login state across multiple AI agent tasks by using a CDP-first connection alongside a persistent user-data-dir. This approach preserves session cookies and local storage, allowing consecutive automated runs to reuse existing login contexts without requiring re-authentication.

What is a CDP-first connection for AI agent browser automation?

A CDP-first connection prioritizes attaching to an existing Chrome DevTools Protocol endpoint to control the browser. This mechanism allows AI agents to directly interface with a running browser instance, ensuring precise tab management and preserving session continuity for automated web testing workflows.

How do I manage browser tabs when automating web testing across different URLs?

Tab management during web testing automation follows precise rules: different URLs automatically open in new tabs, while navigating to the same URL reuses the current open tab. This ensures organized session handling and prevents duplicate browser instances during AI agent execution.

Does browser automation work with an existing CDP-enabled browser or does it launch a new one?

Browser automation supports both scenarios by defaulting to auto-connect with an existing CDP-enabled browser. If an active CDP endpoint is unavailable, it provides a fallback mechanism to automatically launch a new browser instance to execute the required tasks.

What are the limitations of reusing persistent user-data-dir sessions for browser automation?

Persistent user-data-dir sessions require careful handling of concurrent browser instances to avoid profile lock conflicts. Additionally, reusing tabs for the same URL demands careful navigation logic to prevent state loss or unexpected page transitions during automated task execution.