Technical Debt Ratio Calculator (SQALE)

Calculate the technical debt ratio and A–E maintainability rating with the SQALE method SonarQube uses. Free and private: runs in your browser.

Enter remediation minutes and lines of code to get the debt ratio and the maintainability rating, with the formula shown step by step.

Runs entirely in your browser. Nothing you paste is uploaded or stored.

Use cases

  • Check a function before opening a pull request.
  • Explain a review comment with numbers instead of opinions.
  • Find the riskiest code to refactor first.

Frequently asked questions

How does SonarQube calculate the maintainability rating?

Debt ratio = remediation cost ÷ (lines of code × cost to develop one line, 30 minutes by default). A is 5% or less, B up to 10%, C up to 20%, D up to 50%, E above 50%.

Is the Technical Debt Ratio Calculator (SQALE) free?

Yes. It is free with no sign-up, and it runs entirely in your browser, so your input is never uploaded or stored.

How accurate is a browser-based code check?

It uses fast heuristics on the snippet you paste, so it is great for quick feedback. For whole repositories, cross-file analysis and history, run a full CodeInspector scan.

Related tools

Track complexity, duplication and code smells across your whole codebase with CodeInspector.

All free developer tools