Streamline browser automation with a lightweight, efficient solution.
Project details
Public Browser enables efficient Chrome automation without the bulk of traditional tools. With substantial reductions in tokens, costs, and execution times compared to competitors, it provides a seamless experience for driving Chrome using your real profile. Built for advanced use with Claude Code and Cursor, it offers a direct connection via the DevTools Protocol.
Public Browser is a powerful tool that enables seamless interaction with Chrome through direct communication via the Chrome DevTools Protocol (CDP). It allows Claude Code and Cursor to maintain a connection with your real, logged-in Chrome profile, leading to significant efficiency gains. It features:
Built to optimize automated tests, Public Browser supports multi-tab sessions, direct CDP communication, and provides robust accessibility-tree references. It is perfect for those seeking alternatives to middleware like Playwright MCP or Browser MCP.
Installing Public Browser requires a simple command via the respective environment (Claude Code, Cursor, or Cline). After setup, users can initiate Chrome effortlessly and perform tasks such as:
// A sample command to begin a session
claude mcp add --scope user public-browser npx -y public-browser@latest
After installation, tasks can be executed with a plain prompt, illustrating how intuitive the automation process is:
Open mcp-test.second-truth.com, read the page, and fill the contact form with Name "Test User" and Email "test@example.com".
The Script API allows for deterministic browser automation directly from Python, offering a robust alternative for developers looking to create scripts without AI in the loop. Here’s a brief look at how automation can be performed:
from publicbrowser import Chrome
chrome = Chrome.connect()
with chrome.new_page() as page:
page.navigate("https://example.com")
page.fill({"#email": "example@example.com", "#password": "password123"})
page.click("button[type=submit]")
Public Browser allows for the use of existing Chrome profiles, enabling the preservation of cookies, extensions, and logins. Users can easily switch between profiles or create isolated sessions tailored to their testing needs.
Public Browser represents a streamlined solution for automating browser tasks through a direct connection to Chrome. Its efficiency, reliability, and flexibility in handling various automation tasks provide developers and testers with a modern tool to enhance their workflow, making it an excellent alternative in the landscape of browser automation.
Comments
0Start the conversation
Share the first comment.