Analyze Coverage MCP Server

MCP Server that bridges LCOV coverage reports to AI agents

Local serverstdio

What is the Analyze Coverage MCP MCP server?

Analyze Coverage MCP MCP server is a locally run integration for AI assistants that speak the Model Context Protocol. MCP Server that bridges LCOV coverage reports to AI agents.

What you get

MCP server that bridges LCOV coverage reports to AI agents. It runs locally and gives agents precise, structured visibility into test coverage — which lines are hit, which branches are missed, and where to focus testing efforts.

LCOV is a standard text format for code coverage data. It records which lines, functions, and branches were executed during tests. The format is widely supported by test runners (Vitest, Jest, Istanbul, etc.) and is typically written to lcov.info. Each record describes coverage for a source file: line hits, branch hits, and function hits.

What the assistant can call

Once Analyze Coverage MCP is connected, these are the calls the assistant has available:

  • get_coverage_overview — Aggregated and per-file coverage stats (lines, functions, branches %). Supports filtering by directory prefix, threshold, and sort order
  • list_uncovered_regions — Uncovered lines (merged into ranges) and uncovered branches for a specific file
  • get_annotated_source — Full source file annotated line-by-line with [COVERED], [NOT COV], or [NO DATA]. Supports start_line/end_line windowing
  • Vitest — export default defineConfig({ test: { coverage: { provider: 'v8', reporter: ['text', 'lcov'], reportsDirectory: './coverage', }, }, })
  • Jest — The Jest tool exposed by this server
  • Monorepos — In monorepos, project_root is often the repo root (e.g. /repo), but LCOV paths are relative to the package root (e.g. apps/app-api). The MCP handles

Setting it up

Setup follows the usual MCP pattern — install or clone the server, register it in your client's configuration file, restart the client. The configuration blocks on this page cover the common clients.

Configuration and credentials

All MCP tools (get_coverage_overview, list_uncovered_regions, get_annotated_source) require these parameters in every call. They identify which coverage report to load and how to resolve source file paths. | Parameter | Requirement | |-----------|-------------| | lcov_path | Must be an absolute path. The file must exist on disk. | | project_root | Must be an absolute path. In

Choosing this one

Plenty of file and storage access servers cover similar ground. The differences that matter in practice are scope of access and how much setup stands between you and a working tool call. Analyze Coverage MCP's toolset — get_coverage_overview, list_uncovered_regions, get_annotated_source and 3 more — is a fair guide to whether it matches your workflow. It is maintained by sofia-open-source; worth a glance at recent repository activity before you build anything load-bearing on it.

We check each listing at SyncDev against the project's documentation before it goes live — if something here drifts out of date, it is a bug worth reporting.

Before you rely on it

  • It runs with your machine's permissions. That is convenient and also the reason to think about what you point it at before you approve a tool call.
  • MCP clients confirm each tool call by default. Leave that on until you have watched what the analyze coverage mcp mcp server does with a few real requests.

Available tools

ToolWhat it does
get_coverage_overviewAggregated and per-file coverage stats (lines, functions, branches %). Supports filtering by directory prefix, threshold, and sort order.
list_uncovered_regionsUncovered lines (merged into ranges) and uncovered branches for a specific file.
get_annotated_sourceFull source file annotated line-by-line with [COVERED], [NOT COV], or [NO DATA]. Supports start_line/end_line windowing.
Vitestexport default defineConfig({ test: { coverage: { provider: 'v8', reporter: ['text', 'lcov'], reportsDirectory: './coverage', }, }, })
JestThe Jest tool exposed by this server.
MonoreposIn monorepos, project_root is often the repo root (e.g. /repo), but LCOV paths are relative to the package root (e.g. apps/app-api). The MCP handles this automatically:

How to install the Analyze Coverage MCP MCP server

{
  "mcpServers": {
    "analyze-coverage": {
      "command": "npx",
      "args": [
        "-y",
        "@sofia-open-source/analyze-coverage-mcp"
      ]
    }
  }
}

Configuration as documented by the project. Restart the client after saving.

Configuration

All MCP tools (get_coverage_overview, list_uncovered_regions, get_annotated_source) require these parameters in every call. They identify which coverage report to load and how to resolve source file paths. | Parameter | Requirement | |-----------|-------------| | lcov_path | Must be an absolute path. The file must exist on disk. | | project_root | Must be an absolute path. In

Example prompts to try

  • Use Analyze Coverage MCP to get coverage overview.
  • Use Analyze Coverage MCP to list uncovered regions.
  • Use Analyze Coverage MCP to get annotated source.

Frequently asked questions

It connects Analyze Coverage MCP to MCP-compatible AI assistants such as Claude and Cursor, exposing 6 tools (get_coverage_overview, list_uncovered_regions, get_annotated_source, and more) that the assistant can call on your behalf. Instead of copying data back and forth by hand, the assistant works with Analyze Coverage MCP directly.