With the local MCP server, you can connect your AI client to mabl’s testing tools, from creating and running tests locally to analyzing failures in cloud runs.
Prerequisite
To configure and use the mabl MCP, you must have an AI client installed on your system that supports MCP servers.
Setup
The mabl MCP is compatible with any AI client that supports MCP servers. For specific instructions on MCP setup, consult your AI client’s documentation. The following tabbed section provides guidance on how to configure the mabl MCP for specific clients.
Config
To add the mabl MCP server in Claude Desktop, open Claude Desktop Settings from your system’s menu bar: Claude > Settings…
Accessing settings in Claude
In the Settings window, click on the
Developer tab. Click on Edit Config
to open the configuration file for Claude Desktop. This action creates
or opens the existing claude_desktop_config.json file. Depending
on your OS, this file is located in one of the following locations:
-
macOS:
~/Library/Application Support/Claude/claude_desktop_config.json -
Windows:
%APPDATA%Claudeclaude_desktop_config.json
Add the following JSON to configure the mabl MCP server.
{
"mcpServers": {
"mabl-local": {
"command": "npx",
"args": ["@mablhq/mabl-cli@latest", "mcp", "start"],
"env": {}
}
}
}
Start the server
To confirm the mabl MCP server is installed, quit and restart Claude Desktop. When you click on the settings icon at the bottom of the conversation input box, you should see available mabl MCP tools.
Viewing mabl MCP tools in Claude Desktop
Troubleshooting
If setup wasn’t successful, follow these steps to troubleshoot:
Check Claude Desktop errors
On startup, Claude surfaces errors as toast messages. Click on the toast message to review the error and access logs from Developer Settings. Alternatively, you can access it from the Claude Desktop menu bar: Settings > Developer.
Look for error messages containing “mabl” or “MCP”. Common issues include:
- “Command not found” or “No such file or directory”
- “Permission denied”
- Connection timeout errors
Verify your configuration
In your claude_desktop_config.json file, confirm that the
path exists and is executable.
Check for conflicting Node versions
If you have multiple versions of Node installed, Claude may be choosing an unsupported version when it starts up the mabl MCP server. In this situation, try uninstalling all versions of Node and re-installing an LTS version.
For more details on managing MCP servers in Claude Desktop, refer to their official documentation.
Before you start, make sure GitHub Copilot is enabled and you are signed into your GitHub account in VS Code.
Config
To install the mabl MCP in VS Code, visit the setup page and select one of the following options:
- Install - install the mabl MCP for your user profile in VS Code, so that it is accessible across all projects on your local machine.
- Install in Workspace - configure the mabl MCP for a specific workspace, such as a shared project.
Alternatively, if you prefer to manually install the mabl MCP, use the following config block:
{
"inputs": [],
"servers": {
"mabl-local": {
"type": "stdio",
"command": "npx",
"args": [
"@mablhq/mabl-cli@latest",
"mcp",
"start"
]
}
}
}
Start the server
To start the mabl MCP server, click on the start button within the “servers” object.
Make sure the GitHub Copilot chat is set to “Agent” mode before you start
using the mabl MCP.
For more details on managing MCP Servers in VS Code, refer to their
official documentation.
Config
To install the mabl MCP for your user profile in Cursor, visit the setup page and click on the Install button.
Alternatively, if you want to configure the mabl MCP for a specific project,
such as a shared project, create a file named
.cursor/mcp.json in the root of the project directory and
add the following config block:
{
"mcpServers": {
"mabl-local": {
"command": "npx",
"args": [
"@mablhq/mabl-cli@latest",
"mcp",
"start"
]
}
}
}
After saving the file, Cursor should automatically detect the mabl MCP,
and you can enable it.
For more details on managing MCP servers in Cursor, refer to their
official documentation.
Config
You can also connect from any AI client that supports MCP servers. Follow the client’s MCP documentation for setup, and use the following configuration when adding the mab MCP server:
{
"mcpServers": {
"mabl-local": {
"command": "npx",
"args": ["@mablhq/mabl-cli@latest", "mcp", "start"],
"env": {}
}
}
}
Authentication
Before you start using the mabl MCP, you need to be logged in with your user credentials in the mabl CLI. If you aren’t already authenticated in the mabl CLI, your AI client will walk you through how to do that.
Alternatively, you can manually authenticate from the terminal with the command mabl auth login.
Usage
With MCPs, you can carry out your tasks in a back-and-forth dialogue instead of using technical commands. In the AI chat, start sending natural language prompts to interact with the mabl MCP, such as:
- “Is there a test in my mabl workspace that validates…”
- “Get the latest results for that test.”
- “Can you run that test locally? Use this URL…”
Check out the article on mabl local MCP tools for a full list of supported actions.