WebMCP is a proposed web standard for websites to expose their functionality as structured tools that are invoked by AI agents. Chrome DevTools for agents allows your coding agent to interact with these tools directly, helping you analyze and make suggestions on how to make your website WebMCP ready.
By using DevTools for agents, you can verify that your application correctly exposes WebMCP tools, test their execution, and identify areas where AI agents benefit from additional exposed functionality on your site. WebMCP can be implemented on your website with the help of the agentic skills included in Modern Web Guidance.
When working with WebMCP, keep the following in mind:
- Experimental flag: The WebMCP category is not active by default. Use the
--categoryExperimentalWebmcpflag. For more information on participating, see the WebMCP origin trial. - Browser requirements: This feature requires Chrome 149+ with WebMCP features enabled. This means either the website you are testing is enrolled in the WebMCP Origin Trial, or you have manually enabled the corresponding WebMCP flag in your local Chrome browser.
- Target audience distinction: While the DevTools MCP server is a debugging feature targeted at developers, WebMCP tools can be called by any person using a browser agent to interact with websites. DevTools for agents helps you build and test those user-facing WebMCP tools.
Use cases for testing and debugging WebMCP tools
There are a number of ways you can use WebMCP. Every website is different, and so is every set of WebMCP tools. Follow our framework on how to define and build tools that are useful for your website or web application.
For example, if you have a travel agency website with tools to help a user's agent complete relevant actions, here are example prompts that you can use with DevTools for agents to test that your tools work as intended.
Instruct your agent to list and execute WebMCP tools to streamline testing and development.
Note: Agent execution steps are examples of potential behavior. As there are many different types of agents and agents are non-deterministic, you can see different results.
Verify WebMCP tool exposure
When you add WebMCP support to your site, you can task your coding agent to verify that your tools are correctly exposed to the browser and that their input schemas are well-defined.
Example prompt:
Implement a 'book_flight' WebMCP tool to this page to help agents book flights. Verify that it's correctly registered and ready for AI agents to use.
Example agent execution: Your agent detects the need to inspect exposed
tools and autonomously invokes the list_webmcp_tools tool. It parses the
output, confirms whether your tool was successfully registered, and validates
that the schema is well-formed.
Debug WebMCP tool execution
Confirm the internal logic of your WebMCP tool works as expected when called by an AI with specific inputs. You can instruct your agent to execute the tool and monitor the application's response.
Example prompt:
Try using the 'add_to_cart' tool on this page to add product 12345. Let me know if it succeeds or if the application throws any errors.
Example agent execution: Your agent recognizes the intent to test a specific
action. It autonomously determines the correct input schema, uses
execute_webmcp_tool to run it, and monitors the application's response
(including checking console logs) to report back the success status or debug any
failures.
Troubleshoot schema clarity
When an AI agent repeatedly fails to call a WebMCP tool correctly, it is often due to an ambiguous JSON schema. You can ask your agent to review the schema from the perspective of an LLM and suggest improvements.
Example prompt:
My 'schedule_meeting' tool is failing to parse the various date formats sent by different AI agents. Can you review the tool's schema and suggest how I can improve the descriptions or constraints so agents know exactly which format is required?
Example agent execution: Your agent fetches the exposed WebMCP tools and
analyzes the inputSchema for 'schedule_meeting'. It identifies that the date
parameter lacks a clear description or format constraint, and suggests a
corrected JSON schema (for example, adding a description like "Date in
YYYY-MM-DD format") for you to implement in your code.