page-agent README

The project's README from github.com/alibaba/page-agent. As one markdown file: README.md.

Page Agent

Page Agent Banner

CI npm downloads Minzipped bundle size (excluding Zod) license typescript Chrome Web Store Rating GitHub stars

The GUI Agent Living in Your Webpage. One script gives any web page its own AI agent.

alibaba%2Fpage-agent | Trendshift

🌐 English | 中文

🚀 Demo | 📖 Docs | 📢 HN Discussion | 𝕏 Follow on X

Watch the demo


✨ Features

💡 Use Cases

🚀 Quick Start

One-line integration

Fastest way to try PageAgent with our free Demo LLM:

<script
    src="https://cdn.jsdelivr.net/npm/[email protected]/dist/iife/page-agent.demo.js"
    crossorigin="anonymous"
></script>

<!-- China CDN mirror if you can't access jsDelivr -->
<!-- https://registry.npmmirror.com/page-agent/1.12.4/files/dist/iife/page-agent.demo.js -->

⚠️ For technical evaluation only. This demo CDN uses our free testing LLM API. By using it, you agree to its terms.

Add ?autoInit=false to load the script without creating the demo agent automatically. You can then instantiate it with new window.PageAgent(...) and your own LLMs.

NPM Installation

npm install page-agent
import { PageAgent } from 'page-agent'

const agent = new PageAgent({
    model: 'qwen3.5-plus',
    baseURL: 'https://dashscope.aliyuncs.com/compatible-mode/v1',
    apiKey: 'YOUR_API_KEY',
    language: 'en-US',
})

await agent.execute('Click the login button')

For more programmatic usage, see 📖 Documentations.

🤝 Contributing

We welcome contributions from the community! See CONTRIBUTING.md for guidelines and docs/developer-guide.md for local development workflows.

Built something cool with PageAgent? Share it in Show and Tell. 🙌

Please read the maintainer's note on principles and current state.

Contributions generated entirely by bots or AI without substantial human involvement will not be accepted.

⚖️ License

MIT License

👏 Acknowledgments

This project builds upon the excellent work of browser-use.

PageAgent is designed for client-side web enhancement, not server-side automation.

DOM processing components and prompt are derived from browser-use:

Browser Use <https://github.com/browser-use/browser-use>
Copyright (c) 2024 Gregor Zunic
Licensed under the MIT License

We gratefully acknowledge the browser-use project and its contributors for their
excellent work on web automation and DOM interaction patterns that helped make
this project possible.

⭐ Star this repo if you find PageAgent helpful!

page-agent (alibaba/page-agent)

Searching Database…

What is this?Page Agent is a JavaScript GUI agent that lives inside a web page: one script gives the page its own AI assistant you control with natural language.
So is it a browser extension, or a script I embed in my own page?A script you embed — plain in-page JavaScript, no browser extension, Python or headless browser needed. An optional Chrome extension exists only for tasks spanning multiple pages.
How do I add it to a page?Fastest path is a one-line CDN script tag that auto-creates a demo agent; add ?autoInit=false and instantiate new window.PageAgent(...) yourself. For programmatic use, install the NPM package.
Which AI models can drive it — do I need a specific provider?No fixed provider: you bring your own LLM — most mainstream models work, including locally deployed ones. The bundled demo LLM is just a free testing API for technical evaluation.
Can I use it for server-side automation, like scraping?No — it is built for client-side web enhancement inside the pages you ship, not for server-side automation.
What would I actually use this for in a product?Ship an AI copilot inside your SaaS with no backend rewrite, turn 20-click form workflows into one sentence (ERP, CRM, admin tools), add natural-language accessibility, or run agents across tabs.
Does it look at screenshots to understand the page?No screenshots at all — it reads and manipulates the DOM as text, so it needs no multimodal LLMs and no special browser permissions.
What does the MCP server add?PageAgent ships a beta MCP server so external agent clients can control your browser from outside the page, beyond scripts embedded in the site itself.
Is it related to browser-use?Yes — the README credits browser-use as the foundation: PageAgent builds upon its work but runs entirely in-page as client-side JavaScript.
How mature is the project?Young but popular: created in September 2025, already over 29,000 GitHub stars, with the MCP server still marked Beta.
Creator
alibaba
Size
3.6 MB
Stars
29.5K
Age
1y
Commits · 90 Days