> For the complete documentation index, see [llms.txt](https://docs.hivel.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.hivel.ai/integrations/sonarqube.md).

# SonarQube

Connect SonarQube to Hivel to bring code quality and security data directly into your engineering metrics.

#### Choose Your Setup

Pick the option that matches how your team runs SonarQube:

**🌐 Hivel-Managed (SonarCloud)**

**Connect a SonarQube Cloud (SonarCloud) account**

For teams using the hosted SaaS version (URL like `sonarcloud.io`)

**Setup:**

* Generate a token
* Paste the base URL
* Done: no infrastructure changes needed

{% content-ref url="/pages/aFsqkMPNKqknmsBcSjmJ" %}
[Hivel-managed](/integrations/sonarqube/hivel-managed.md)
{% endcontent-ref %}

**🔒 On-Prem (Self-Hosted)**

**Connect a self-hosted SonarQube Server**

For teams running SonarQube Server on your own infrastructure

**Setup requires:**

1. Whitelist Hivel's IPs so it can reach your server
2. Create a webhook so SonarQube can notify Hivel
3. Generate and provide a token
4. Provide the base URL

{% content-ref url="/pages/DGvewh08RGNofjF5KfEg" %}
[On-Prem](/integrations/sonarqube/on-prem.md)
{% endcontent-ref %}

#### What You'll Get

Once connected, Hivel brings in:

* Code quality metrics
* Security vulnerabilities
* Bugs and code smells
* Full integration with your engineering analytics
