Allows to interact with web pages by performing actions such as clicking buttons, filling out forms, and navigating links. It works by remote controlling Google Chrome or Chromium browsers using the Chrome DevTools Protocol (CDP). When Claude needs to browse the web, it can use this skill to do so.
Allows to interact with web pages by performing actions such as clicking buttons, filling out forms, and navigating links. It works by remote controlling Google Chrome or Chromium browsers using the Chrome DevTools Protocol (CDP). When Claude needs to browse the web, it can use this skill to do so.
license
Stolen from Mario
Web Browser Skill
Full-featured browser automation with CDP tools for collaborative site exploration.
💾 持久化存储:默认使用 Chromium 浏览器,数据持久化保存在 ~/.cache/scraping-web-browser/,包括 cookies、localStorage、session data 等,重启后自动恢复。
Quick Start
# Run demo to test everything works
node demo.js
# Get current port
node scripts/get-port.js
# Start Chromium browser (default, with persistent storage)
node scripts/start.js
Browser Management
Start Chromium (Default)
```bash
./scripts/start.js # Start Chromium with persistent storage
./scripts/start.js --chrome # Use Google Chrome instead of Chromium
```
Start Chromium on a random port (9222-9999) with remote debugging. The port is saved and reused for subsequent starts.
Important: This skill starts a completely independent browser instance with its own profile directory (~/.cache/scraping-web-browser). It will NOT affect your existing Chrome browser or close any open tabs. The browser runs in the background and persists cookies, localStorage, and session data between restarts.
Stop Chrome
```bash
./scripts/stop.js # Stop the browser
```
Gracefully stop the browser. Port configuration is preserved for next start.
Get Port
```bash
./scripts/get-port.js # Show current port
```
```bash
./scripts/reload.js # Normal reload
./scripts/reload.js --force-cache # Force using cache
./scripts/reload.js --force-no-cache # Force reload without cache
```
Reload the current page with cache control.
Tabs
```bash
./scripts/tabs.js list # List all tabs
./scripts/tabs.js new # Open new tab
./scripts/tabs.js new "https://example.com" # Open new tab with URL
./scripts/tabs.js switch 1 # Switch to tab by index
./scripts/tabs.js close 0 # Close tab by index
./scripts/tabs.js close-others # Close all other tabs
```
```bash
./scripts/cookies.js list
./scripts/cookies.js get "session"
./scripts/cookies.js set "token" "abc123"
./scripts/cookies.js delete "session"
./scripts/cookies.js clear
./scripts/cookies.js export cookies.json
./scripts/cookies.js import cookies.json
```
Manage cookies (list, get, set, delete, clear, export, import).
Storage
```bash
./scripts/storage.js list
./scripts/storage.js get local "token"
./scripts/storage.js set local "user" '{"name":"John"}'
./scripts/storage.js delete session "temp"
./scripts/storage.js clear local
```
Manage localStorage and sessionStorage.
Clear Data
```bash
./scripts/clear-data.js cookies
./scripts/clear-data.js localStorage
./scripts/clear-data.js sessionStorage
./scripts/clear-data.js cache
./scripts/clear-data.js all
```
```bash
./scripts/scroll.js down 500
./scripts/scroll.js up 500
./scripts/scroll.js top
./scripts/scroll.js bottom
./scripts/scroll.js element "#section"
```