Sonar MCP Server

A local MCP server providing read-only access to a SonarQube Community Build (26.4+) instance via its web-api. It lets AI agents (Claude Code, Cursor, VS Code Copilot, etc.) fetch a project's issue…

Local serverstdio

What is the Sonar MCP Server?

sonar-mcp-server is an MCP project maintained in the igorolv/sonar-mcp-server repository. The maintainer describes its purpose as “A local MCP server providing read-only access to a SonarQube Community Build (26.4+) instance via its web-api. It lets AI agents (Claude Code, Cursor, VS…”. Read the project documentation for the complete scope.

Source

Project documentation · Repository · Discovery listing. This profile records the public documentation checked on 2026-10-08.

Recorded tools

Check the linked publisher documentation and your connected client's tool list. Names and availability can vary with the server version and account permissions.

ToolWhat it does
listProjectsList of SonarQube projects. Parameters: query (name substring), limit, offset. Returns key, name, qualifier.
listComponentsSearch/browse components inside a project using Sonar's component tree. Parameters: projectKey, query, qualifiers, branch / pullRequest, limit, offset. Returns
getProjectProject overview: header info (name, qualifier, visibility, description, version, last analysis date), quality gate status with failed conditions, and…
listProjectBranchesList of branches analysed for the project. Each entry: name, isMain, type (LONG/SHORT/BRANCH), excludedFromPurge, analysisDate, qualityGateStatus, plus…
listProjectPullRequestsList of PR analyses for the project. Each entry: PR key (use as pullRequest= elsewhere), title, branch (head), base, url, analysisDate, qualityGateStatus, plus
listIssuesFlat list of issues for a project. Parameters: projectKey (required unless defaulted), componentPathPrefix (opt.) — a single subtree-or-file filter relative to
getIssueDetails of a single issue by key plus its change history (changelog). Accepts optional branch / pullRequest.
getIssueSnippetsSource-code snippets around all issue locations (primary plus flows for cross-file rules). For each location: componentPath, language, and an array of source…
getProjectIssuesSummaryAggregated summary of open issues in a project: total plus breakdowns by severity, type, status, rule, tag, and SCM author. Parameters mirror listIssues (incl.
getProjectIssuesBreakdownMulti-module aggregation of issues by logical module and rule. Module is derived from the first componentPath segment. Parameters mirror…
getRuleDetails of a Sonar rule by key (e.g. java:S1234): title, severity, type, language, tags, description sections (introduction, root cause, how to fix…
listHotspotsList of Security Hotspots for a project. Hotspots are a separate category from issues, marking spots that require manual security review. By default Sonar…
getHotspotSecurity Hotspot details: full rule description (risk, vulnerability, fix recommendations), primary textRange, secondary flows, changelog. Hotspot keys are…
VariableTools in the group
SONAR_MCP_TOOLS_ISSUElistIssues, getIssue, getIssueSnippets, getProjectIssuesSummary, getProjectIssuesBreakdown
SONAR_MCP_TOOLS_PROJECTlistProjects, listComponents, getProject, listProjectBranches, listProjectPullRequests
SONAR_MCP_TOOLS_HOTSPOTlistHotspots, getHotspot
SONAR_MCP_TOOLS_RULEgetRule