chromium-mcp
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@chromium-mcpfetch https://example.com as markdown"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Chromium MCP
MCP server for web fetching and automation using Chromium headless browser.
Reason behind this repository
I didn't wanna waste my "limited" tokens on Z.ai coding plan, therefore I made my own MCP to interact with the web, feel free to propose enhancements or new features.
Related MCP server: pulldown
Features
fetch_page: Fetch web pages and convert to markdown/HTML
screenshot: Take screenshots of web pages or specific elements
interact: Automate browser interactions (click, fill, scroll, wait)
extract_data: Extract structured data using CSS selectors
get_link: Get link information and follow redirects
Installation
From Git Repository
# Clone the repository
git clone https://github.com/gzigurella/chromium-mcp.git
cd chromium-mcp
# Create virtual environment
python3 -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
# Install the package
pip install -e .
# Install Chromium browser (required)
playwright install chromiumWith uv (recommended)
# Clone and enter directory
git clone https://github.com/gzigurella/chromium-mcp.git
cd chromium-mcp
# Install with uv
uv pip install -e .
# Install Chromium
playwright install chromiumIntegration
OpenCode
Add to your ~/.config/opencode/opencode.json:
{
"mcpServers": {
"chromium-fetch": {
"type": "local",
"command": [
"/path/to/chromium-mcp/venv/bin/python",
"-m",
"chromium_mcp"
],
"enabled": true
}
}
}Claude Desktop
Add to your Claude Desktop config:
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
Linux: ~/.config/Claude/claude_desktop_config.json
{
"mcpServers": {
"chromium-fetch": {
"command": "/path/to/chromium-mcp/venv/bin/python",
"args": ["-m", "chromium_mcp"]
}
}
}Generic MCP Client
For any MCP-compatible client:
# Start the server directly
/path/to/venv/bin/python -m chromium_mcpThe server communicates via stdio using the MCP protocol.
Tools
fetch_page
Fetch a web page and return content as markdown or HTML.
Parameter | Type | Required | Default | Description |
url | string | Yes | - | URL to fetch |
format | string | No | "markdown" | Output format: "markdown" or "html" |
timeout | integer | No | 30 | Timeout in seconds |
wait_for | string | No | null | CSS selector to wait for |
{
"url": "https://example.com",
"format": "markdown",
"timeout": 30,
"wait_for": ".main-content"
}screenshot
Take a screenshot of a web page.
Parameter | Type | Required | Default | Description |
url | string | Yes | - | URL to screenshot |
format | string | No | "png" | Image format: "png" or "jpeg" |
quality | integer | No | 80 | JPEG quality (1-100) |
full_page | boolean | No | false | Capture full page |
selector | string | No | null | CSS selector for element |
timeout | integer | No | 30 | Timeout in seconds |
{
"url": "https://example.com",
"format": "png",
"full_page": true
}interact
Interact with web page elements sequentially.
Parameter | Type | Required | Default | Description |
url | string | Yes | - | URL to interact with |
actions | array | Yes | - | List of actions |
timeout | integer | No | 30 | Timeout in seconds |
Action Types:
click: Click element by selectorfill: Fill input fieldselect: Select dropdown optionscroll: Scroll pagewait: Wait for element
{
"url": "https://example.com/search",
"actions": [
{"type": "fill", "selector": "input[name='q']", "value": "test search"},
{"type": "click", "selector": "button[type='submit']"},
{"type": "wait", "selector": ".results", "milliseconds": 2000}
]
}extract_data
Extract structured data using CSS selectors.
Parameter | Type | Required | Default | Description |
url | string | Yes | - | URL to extract from |
selectors | array | Yes | - | List of extraction rules |
timeout | integer | No | 30 | Timeout in seconds |
{
"url": "https://example.com/products",
"selectors": [
{"name": "titles", "selector": "h2.product-title", "multiple": true},
{"name": "prices", "selector": ".price", "multiple": true},
{"name": "links", "selector": "a.product-link", "attribute": "href", "multiple": true}
]
}get_link
Get link href and text, optionally following navigation.
Parameter | Type | Required | Default | Description |
url | string | Yes | - | URL of page containing link |
selector | string | Yes | - | CSS selector for anchor |
click | boolean | No | false | Follow the link |
timeout | integer | No | 30 | Timeout in seconds |
{
"url": "https://example.com",
"selector": "a.download",
"click": true
}Configuration
Environment Variables
Variable | Default | Description |
CHROMIUM_PATH | auto | Path to Chromium executable |
HEADLESS | true | Run browser in headless mode |
TIMEOUT | 30 | Default operation timeout |
DEBUG | false | Enable debug logging |
# Example
export TIMEOUT=60
export HEADLESS=false
python -m chromium_mcpDevelopment
Running Tests
source venv/bin/activate
pytest
# With coverage
pytest --cov=src --cov-report=htmlProject Structure
chromium-mcp/
├── src/chromium_mcp/
│ ├── __init__.py
│ ├── __main__.py
│ ├── server.py
│ └── tools/
│ ├── __init__.py
│ ├── fetch_page.py
│ ├── screenshot.py
│ ├── interact.py
│ ├── extract_data.py
│ └── get_link.py
├── tests/
├── pyproject.toml
└── README.mdTroubleshooting
Browser Not Found
playwright install chromiumPermission Issues (Linux)
sudo sysctl -w kernel.shmmax=268435456Timeout Errors
export TIMEOUT=60Security
file://URLs are blockedCredentials are never logged
Browser processes are always cleaned up
All operations have configurable timeouts
License
MIT
Available Tools
5 toolsextract_dataA
Extract structured data from a web page using CSS selectors. Returns JSON with extracted text content or attribute values. Supports single element, multiple elements, and attribute extraction.
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | The URL to extract data from (must be http or https) | |
| selectors | Yes | List of CSS selectors with extraction rules | |
| timeout | No | Timeout in seconds (default: 30) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided, so description carries full burden. It discloses that it returns JSON with text or attributes, supports multiple and attribute extraction. Does not mention error handling or timeouts, but core behavior is clear.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences, no fluff, front-loaded with core action and returns. Efficient and clear.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
No output schema, but description mentions JSON return with text or attribute values. For a simple 3-parameter tool, this is adequate. Could briefly mention error cases or sibling differentiators.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
100% schema description coverage means the schema already explains each parameter well. The description adds no extra parameter-level detail beyond the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Clearly states the tool extracts structured data from a web page using CSS selectors, distinguishing it from siblings like fetch_page (raw content) and get_link (links). Specifies return type and capabilities.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Does not explicitly state when to use this tool versus alternatives like fetch_page or get_link. The description implies it's for selective extraction, but no direct guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
fetch_pageB
Fetch a web page using Chromium headless browser and return content as markdown or HTML. Useful for reading web pages, extracting content from dynamic sites that require JavaScript rendering.
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | The URL to fetch (must be http or https) | |
| timeout | No | Timeout in seconds (default: 30) | |
| wait_for | No | Optional CSS selector to wait for before extracting content. Useful for pages that load content dynamically. | |
| format | No | Output format - 'markdown' (default) or 'html' | markdown |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description must fully disclose behavior. It mentions Chromium headless browser (implying resource usage) but does not cover side effects, authentication needs, rate limits, or what happens to the browser instance after use. This is insufficient for a tool with no annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences are concise and front-load the core action and utility. No unnecessary information, though a slightly more structured format (e.g., mentioning intended use) could improve readability.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description hints at return format and browser usage but lacks details on error behavior, timeouts beyond parameter, or handling of network failures. Given no output schema, more completeness would be beneficial.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so the schema already documents all 4 parameters well. The description adds minimal value beyond confirming output format ('markdown' or 'html'), which is already in the schema. Baseline score of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states it fetches a web page using Chromium and returns content in markdown or HTML, with specific mention of dynamic sites requiring JavaScript rendering. It distinguishes from siblings like screenshot or interact, but does not explicitly contrast with them.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description indicates usefulness for dynamic sites but lacks explicit when-not-to-use guidance or comparison with sibling tools (e.g., when to use fetch_page vs extract_data). No exclusions or prerequisites are mentioned.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_linkA
Get link href and text from a web page. By default extracts href without clicking. When click=true, follows the link and returns the final URL. Useful for extracting download links, checking redirect destinations, or getting link text.
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | The URL of the page containing the link (must be http or https) | |
| selector | Yes | CSS selector for the anchor element | |
| click | No | Click the link and follow navigation (default: False) | |
| timeout | No | Timeout in seconds (default: 30) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided, so description carries full burden. It discloses default behavior (extract href without clicking) and the click mode (follows link, returns final URL). Also mentions timeout. Does not contradict any annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three sentences, no fluff. First sentence states main purpose, second explains default vs click, third lists use cases. Every sentence is informative and concise.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
No output schema, but description implies return of href and text. Covers both modes and all parameters. Lacks explicit detail on return format (e.g., structure of response), but adequate for agent understanding.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so baseline 3. Description adds context for the click parameter (explains behavior difference) and timeout is already described in schema. No significant extra value beyond schema for url and selector.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Description clearly states it gets link href and text from a web page, distinguishes between default extraction and click behavior, and lists specific use cases (extracting download links, checking redirect destinations, getting link text). This is specific and distinguishes from sibling tools.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly describes when to use (extracting links, checking redirects, getting link text) and the two modes (default vs click). However, lacks explicit exclusions or comparisons to sibling tools like fetch_page or interact for alternative scenarios.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
interactA
Interact with web page elements using Chromium headless browser. Execute actions like click, fill, select, scroll, and wait in sequence. Returns the final page content as markdown after all actions are executed.
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | The URL to interact with (must be http or https) | |
| actions | Yes | List of actions to execute in sequence | |
| timeout | No | Timeout in seconds (default: 30) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the burden. It discloses that the tool returns markdown after all actions, which is behavioral. However, it lacks details on error handling (e.g., if a selector fails), timeouts, or any side effects. Still, the core behavior is clear.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences: first states purpose and technology, second lists actions and output. Front-loaded with key information, no fluff. Every sentence earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given no output schema, the description provides the return format (markdown). The tool has three parameters with full schema descriptions, and siblings are distinct. The description is sufficient for an agent to understand the tool's role and how to use it.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so baseline 3. The description adds meaning by stating that actions are executed in sequence and that the final result is markdown, which the schema lacks (no output schema). However, it does not go beyond listing the same action types already in the enum.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: interacting with web page elements via a Chromium headless browser, executing actions like click, fill, select, scroll, and wait in sequence, and returning the final page content as markdown. This distinguishes it from siblings like fetch_page (raw fetch) or extract_data (likely extraction), making it specific.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for interactive sequences but does not explicitly state when to use this tool versus alternatives (e.g., when no interaction is needed, use fetch_page). No when-not-to-use or alternative tool names are provided.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
screenshotA
Take a screenshot of a web page using Chromium headless browser. Returns base64-encoded image. Supports PNG and JPEG formats, full page screenshots, and element screenshots via CSS selector.
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | The URL to screenshot (must be http or https) | |
| format | No | Image format - 'png' (default) or 'jpeg' | png |
| quality | No | JPEG quality 1-100 (default: 80, only for jpeg) | |
| full_page | No | Take full page screenshot (default: False) | |
| selector | No | Optional CSS selector for element screenshot | |
| timeout | No | Timeout in seconds (default: 30) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full burden and does well: it discloses the headless browser tech, base64 output, and supported formats. However, it omits details like error handling (e.g., page load failures) or behavior with dynamic content, but overall it provides sufficient transparency for a screenshot tool.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is extremely concise: two sentences with no wasted words. The first sentence front-loads the primary action and output format, while the second adds key variations. Every sentence earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given that there is no output schema and 6 parameters, the description is fairly complete for a simple tool. It covers the main use cases (normal, full page, element). However, it does not mention error scenarios or return structure (e.g., base64 string details), which would improve completeness.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so baseline is 3. The description adds value by grouping features (e.g., 'full page screenshots' maps to full_page, 'element screenshots via CSS selector' maps to selector). It doesn't repeat schema descriptions but provides conceptual context, earning a score above baseline.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's action ('Take a screenshot'), the resource ('a web page'), and the method ('Chromium headless browser'). It also lists supported formats and features, making the purpose unmistakable. It distinguishes from sibling tools (like fetch_page or extract_data) by focusing on visual capture.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives (e.g., fetch_page for text content). It lacks explicit 'when-to-use' or 'when-not-to-use' instructions. Without this, an AI agent may incorrectly select this tool for non-visual tasks.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
5 tool updates
v0.1.0- First observed
extract_data - First observed
fetch_page - First observed
get_link - First observed
interact - First observed
screenshot
TDQS
Each tool has a clearly distinct purpose: fetching full page, extracting data via selectors, getting link info, interacting with elements, and taking screenshots. No overlap or ambiguity.
All tool names follow a consistent verb_noun pattern (e.g., fetch_page, extract_data, get_link, interact, screenshot). No mixing of conventions.
5 tools is well-scoped for a browser automation server, covering the essential workflows without being excessive or insufficient.
The tool set covers core web scraping needs: fetching, extracting, interacting, and screenshots. Minor gaps exist (e.g., cookie handling, network capture), but the surface is largely complete for common use cases.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
MCP server (stdio): fetch web pages as clean readable markdown via the AgentForge API
MCP server for web extraction and rendering via AceDataCloud WebExtrator
Free remote MCP server for fetching public web pages through a rotating proxy pool.
Stealth web browser for agents: search, fetch, click, download and type in persistent MCP sessions.
Related MCP Servers
- AlicenseNot gradedqualityAmaintenanceRemote MCP server for web scraping with anti-bot evasion. Provides stealth HTTP fetching, headless browser with Cloudflare bypass, CSS selectors, YouTube transcripts, and Markdown conversion.1MIT
- AlicenseNot gradedqualityCmaintenanceMCP server for retrieving web pages as clean Markdown, with configurable detail levels and optional Chromium rendering for JavaScript-heavy pages.1MIT
- FlicenseNot gradedqualityDmaintenanceMCP server for headless browser automation using Puppeteer, enabling AI to navigate, click, fill forms, take screenshots, and execute JavaScript on web pages.-
- FlicenseNot gradedqualityDmaintenanceMCP server to scrape web pages to clean Markdown via headless Chromium, with support for single or batch URLs.-
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/gzigurella/chromium-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server