On this page
SonarQube is a static analysis platform from Sonar that scans source code without running it, reports bugs, security vulnerabilities and code smells, and can block a pull request when results fail a quality gate. It runs in your CI pipeline and gives each change a pass or fail.
The name covers a product family: SonarQube Server (self-managed), SonarQube Cloud (hosted, formerly SonarCloud) and SonarQube for IDE (editor extension, formerly SonarLint), per sonarsource.com/products/sonarqube on 24 November 2026.
What does SonarQube mean?
"SonarQube" is the product name, and it describes a rules-based code quality and security scanner. Sonar's own site now describes it as a platform for code verification and governance, one that "verifies code, whether a developer or an AI agent wrote it, before it ships" (sonarsource.com, 24 November 2026). In day-to-day use, engineers mean the dashboard and the pull request check that report issues against a set of rules for the language in the repository.
Sonar says it is trusted by over 7 million developers and 75% of the Fortune 100 (sonarsource.com, 24 November 2026). That reach is why "SonarQube" shows up as a line item in security questionnaires and engineering standards, and why people search for its definition before they ever install it.
What is SonarQube used for?
Teams use SonarQube for three jobs: catching bugs and vulnerabilities in new code, enforcing a merge standard, and reporting a code quality trend to managers and auditors. All three come from one analysis run, which happens in CI each time code is pushed or a pull request opens.
| Job | How SonarQube does it |
|---|---|
| Find problems | Rules per language report issues as bugs, vulnerabilities and code smells, with a remediation hint on each |
| Enforce a standard | A quality gate passes or fails the analysis, and a failing gate can block the merge |
| Report | A dashboard shows reliability, security and maintainability ratings, coverage, duplication and technical debt per project |
Scroll the table sideways to see every column.
SonarQube is also a SAST tool: Sonar's product page says "SonarQube includes SAST, and goes beyond it", covering injection flaws, secrets and IaC scanning in your own code. Dependency scanning (software composition analysis), dependency-aware taint analysis and SBOM export are an add-on, SonarQube Advanced Security for Cloud and Server, per Sonar's products page.
How does SonarQube work?
SonarQube works in two parts: a scanner runs in your build and parses the code, and a server or cloud service stores the results and renders them. The scanner sends analysis to SonarQube Server or SonarQube Cloud, which applies the rules, tracks issues across analyses and evaluates the quality gate. After installing a server you add "one or more Sonar scanners" on the machines where analysis runs, per the server installation docs.
The loop most teams run is the same one:
- A developer pushes a branch or opens a pull request.
- CI runs the scanner on the checkout, with coverage reports attached if you have them.
- The server computes issues and measures, and evaluates the quality gate.
- The result appears as a check on the pull request and on the project dashboard.
- A failing gate blocks the merge until the issues are fixed or marked.
Because the rules are deterministic, the same code gives the same findings every time. That predictability is the main reason teams trust it as a gate.
What does a SonarQube quality gate check?
A quality gate is a set of pass or fail conditions evaluated on each analysis, and the built-in "Sonar way" gate applies four conditions to new code. Per the SonarQube Server docs on 24 November 2026:
| Condition | Threshold |
|---|---|
| New issues | None introduced |
| New security hotspots | All reviewed (deprecated condition) |
| Test coverage on new code | At least 80.0% |
| Duplication in new code | At most 3.0% |
Scroll the table sideways to see every column.
The ratings are one way to evaluate the first condition: it fails if the issue count is above zero or if the Reliability, Security or Maintainability rating is worse than A. Focusing on new code is deliberate. It lets a team with a legacy codebase hold every change to a standard without fixing ten years of history first.
What does SonarQube report?
SonarQube sorts findings by the quality they affect: reliability, security and maintainability. Its metrics reference lists "Reliability issues", "Security issues" and "Maintainability issues" as counts of issues impacting each, plus code smells and security hotspots, which need a human to review whether the flagged code is safe.
Two measures need a definition because they are easy to misread.
- Technical debt in SonarQube is "the sum of the maintainability issue remediation costs", where each issue's cost is the effort in minutes to fix it. It measures the cost of fixing every flagged issue, not the cost of changing the code in future.
- Technical debt ratio is the ratio between the cost to fix the software and the cost to develop it, computed from the debt, a per-line development cost and the line count.
Both come from the metrics definition page. If you want the wider idea, read what technical debt is and how to measure it, and the glossary entry on code smells.
What are the SonarQube editions and products?
SonarQube comes as a free self-hosted Community Build, paid Server editions, and SonarQube Cloud. Sonar describes Community Build as "an open source edition suitable for developers and small teams" (sonarsource.com/plans-and-pricing, 24 November 2026).
| Product | Where it runs | Notes as of 24 November 2026 |
|---|---|---|
| SonarQube Community Build | Self-managed | Free and open source; analyzes the main branch only, with no pull request analysis, per Sonar's edition comparison |
| SonarQube Server (Developer, Enterprise, Data Center) | Self-managed, can run air-gapped | Branch and pull request analysis start at Developer; priced per instance per year by lines of code |
| SonarQube Cloud | Hosted by Sonar | Free for private projects up to 50K lines; Team starts at $34 a month for up to 100K lines |
| SonarQube for IDE | Your editor | Free extension that shows issues while you type |
| SonarQube Advanced Security | Add-on to Cloud and Server | Dependency scanning, advanced taint analysis and SBOM export |
Scroll the table sideways to see every column.
Sonar says SonarQube covers more than 45 languages, frameworks and Infrastructure-as-Code platforms, and its plans page lists a lower count (35+ or 40+) for the smaller plans. Language counts differ by plan and edition, so check the one you plan to run. Prices by edition are in SonarQube pricing in 2026.
What does SonarQube not tell you?
SonarQube tells you what is wrong with the code as it stands today, and says nothing about which of those problems matter to your team this month. It analyzes a snapshot. It does not read git history, so a code smell in a file untouched for three years and a code smell in the file changed every week look the same on the issue list.
That gap is large in practice. We analysed 195 of the most-starred public repositories indexed on repowise.dev (1,000+ GitHub stars each, 253,688 production source files, November 2026):
| Finding across 195 repos | Result |
|---|---|
| Line churn in the busiest 10% of files, 90 days, median repo | 68% |
| Health of hotspot files (median) vs. the repo as a whole | 4.9 vs. 7.1 out of 10 |
| Share of bug-fixed files that sit in the least-healthy 20% of files, median repo | 60% |
| Repos with at least one file nothing imports | 170 of 190 (89%) |
| Repos with at least one circular import group | 173 of 195 (89%) |
| Files with one author making 80%+ of commits (bus factor 1), median repo | 60% |
Scroll the table sideways to see every column.
These measures need the dependency graph and the commit history, which a per-file rules engine does not have. The full method is in the state of open-source code health report. The takeaway for a team is simple: a list of 4,000 open issues is a backlog, while the 40 issues in the files that change every week are a plan.
How does repowise relate to SonarQube?
repowise answers the question SonarQube leaves open: which files should we fix first, and what is the first edit? It scores every file from 1 to 10 using the parse tree, the dependency graph and git history, needs no LLM key or network for that, and runs inside repowise init and repowise update (code health layer).
repowise init # full index; scores every file
repowise health # fix first list, KPIs, lowest-scoring files
repowise update # re-scores only the files that changed
The output starts with a ranked "Fix first" list. Each item names the symbol to change, the effort, the health gain on that file and the test to run to verify it. Code health is one of several layers from the same index: dead code, change risk, ownership and refactoring plans. Agents reach all of it over MCP through ten tools, so the ranking is available inside the editor session as well as on a dashboard.
Teams run both. SonarQube enforces a rule set on every pull request, and repowise ranks where a limited amount of refactoring time pays back. If you are weighing a switch, the full side-by-side is on the SonarQube alternative page, and ranked options are in SonarQube alternatives in 2026.
How we checked
On 24 November 2026 we read sonarsource.com/products/sonarqube, sonarsource.com/plans-and-pricing, Sonar's edition comparison, and the SonarQube Server docs for quality gates, metrics and installation. Every SonarQube statement above comes from those pages. The former product names (SonarCloud, SonarLint) are Sonar's earlier names for the Cloud and IDE products. The repowise figures come from our dataset of 195 public repositories, production code only, pulled 10 November 2026.
FAQ
- What is SonarQube?
- SonarQube is a static analysis platform from Sonar. It scans source code without running it, reports bugs, vulnerabilities and code smells, and can fail a pull request through a quality gate. It is available as self-managed SonarQube Server and as the hosted SonarQube Cloud.
- What is SonarQube used for?
- Teams use it to catch bugs and security flaws in new code, to enforce a merge standard through a quality gate, and to report code quality ratings, coverage and technical debt on a dashboard. It runs in CI on each push or pull request.
- What does SonarQube mean?
- SonarQube is a product name, not an acronym. It refers to Sonar's code quality and security platform, and people use it for the dashboard and pull request check that report issues against language rules.
- How does SonarQube work?
- A scanner in your CI parses the code and sends the analysis to SonarQube Server or SonarQube Cloud. The server applies the rules, tracks issues between runs, computes measures such as coverage and duplication, and evaluates the quality gate. The result appears on the pull request and the dashboard.
- Is SonarQube free?
- Partly. SonarQube Community Build is free and open source, and SonarQube Cloud is free for private projects up to 50K lines of code, as of 24 November 2026. Developer, Enterprise and Data Center editions of Server are paid, priced per instance by lines of code. See SonarQube pricing.
- Is SonarQube a SAST tool?
- Yes. Sonar states that SonarQube includes SAST, which checks your own source code for security flaws such as injection without running it. Dependency scanning and dependency-aware taint analysis are an add-on, SonarQube Advanced Security.
- What is a SonarQube quality gate?
- A quality gate is a set of pass or fail conditions checked on each analysis. The built-in Sonar way gate requires no new issues, all new security hotspots reviewed, at least 80% coverage and at most 3% duplication on new code.
- What does SonarQube technical debt mean?
- In SonarQube, technical debt is the sum of the effort, in minutes, to fix every maintainability issue it found. It is a remediation estimate on the current snapshot, not a measure of how much the code slows future changes.
- Does SonarQube analyze git history?
- Not for ranking findings. It tracks issues between analyses and attributes new code, but it does not score files by churn, co-change or ownership. repowise does, so it can rank files by how costly they are to leave as they are.
- What are the alternatives to SonarQube?
- Semgrep and Opengrep for rules and security, Qlty and Codacy for hosted quality checks, CodeScene for behavioural analysis, and repowise for ranked code health from graph and git history. Prices and picks by team size are in SonarQube alternatives in 2026, and per-language tools are in the best static analysis tools by language.
- Can SonarQube detect dead code?
- Partly, inside a file: it has rules for unused local variables, unused private members and unreachable statements. It does not use the import graph to find whole files or exports that nothing in the repository references. repowise does that from the dependency graph, and finds at least one dead code finding in 182 of 190 public repos (96%) in our dataset.
- Can SonarQube be run locally?
- Yes. SonarQube Community Build is free and self-hosted, so you can run the server on your own machine, then run a scanner against your project and open the dashboard. SonarQube for IDE checks code in your editor without a server.
- Which is the best tool for code review?
- It depends on what you want reviewed. SonarQube checks pull requests against rules and a quality gate. AI review tools comment in plain language on the diff. repowise adds change risk, owners and the files a change would break. Many teams combine a rule-based gate with one of the others.



