# Introduction to Azure DevOps integration

The integration is compatible with both Azure DevOps Server and Azure DevOps Services.

## Key features

With this integration, you’ll be able to:

* Import your Azure DevOps repositories into SonarQube Server to easily set up SonarQube Server projects.
* Smoothly integrate your SonarQube Server analysis into your Azure build pipeline with our [sonarqube-extension-for-azure-devops](https://docs.sonarsource.com/sonarqube-server/analyzing-source-code/scanners/sonarqube-extension-for-azure-devops "mention"). This includes multi-branch analysis features. See these pages for ALM-specific instructions for adding your analysis using yaml or the Azure Classic editor:
  * [gradle-or-maven-project](https://docs.sonarsource.com/sonarqube-server/devops-platform-integration/azure-devops-integration/adding-analysis-to-pipeline/gradle-or-maven-project "mention")
  * [dotnet-project](https://docs.sonarsource.com/sonarqube-server/devops-platform-integration/azure-devops-integration/adding-analysis-to-pipeline/dotnet-project "mention")
  * [c-family-project](https://docs.sonarsource.com/sonarqube-server/devops-platform-integration/azure-devops-integration/adding-analysis-to-pipeline/c-family-project "mention")
  * [js-ts-go-python-php](https://docs.sonarsource.com/sonarqube-server/devops-platform-integration/azure-devops-integration/adding-analysis-to-pipeline/js-ts-go-python-php "mention")
  * [monorepo-projects](https://docs.sonarsource.com/sonarqube-server/devops-platform-integration/azure-devops-integration/adding-analysis-to-pipeline/monorepo-projects "mention")
* Report the analysis’ quality gate status right in Azure Pipeline’s Build Summary page.
* [#prevent-pull-request-merges-when-the-quality-gate-fails](https://docs.sonarsource.com/sonarqube-server/devops-platform-integration/setting-up-project-integration#prevent-pull-request-merges-when-the-quality-gate-fails "mention").
* View issues detected on a pull request in Azure DevOps.\
  Each issue will be a comment on the Azure DevOps pull request. If you change the status of an issue in SonarQube Server, that status change is immediately reflected in the Azure DevOps interface.

<figure><img src="broken-reference" alt="SonarQube integration with Azure DevOps is done based on Azure DevOps extension for SonarQube."><figcaption></figcaption></figure>

{% hint style="info" %}
Check out this [video](https://www.youtube.com/watch?v=oYvMmN6G3F0) on SonarQube Server integration with Azure DevOps.
{% endhint %}

## Integration solution overview <a href="#related-pages" id="related-pages"></a>

Integration is performed at two levels:

* Global: Within your SonarQube instance, an “Azure DevOps Configuration” record is used to manage the SonarQube access to your Azure DevOps Services organization or Azure DevOps Server collection. This record stores:
  * Your organization’s or collection’s URL.
  * An Azure DevOps Personal Access Token (PAT) which is used by SonarQube to access your Azure DevOps Services organization or Azure DevOps Server collection. This PAT is usually created from a dedicated technical account. &#x20;
* Project: A project administrator must provide  Azure DevOps PAT to import their Azure DevOps repository to SonarQube. SonarQube stores this PAT in its database, enabling it to list and import the repositories the administrator can access.

It means that SonarQube uses two different Azure DevOps PATs:

* The global PAT to access your organization or collection in order to import repositories or report the quality gate status in Azure Pipelines.
* The project PAT to check the user's permissions on repositories when a user imports Azure DevOps repositories.

<figure><img src="broken-reference" alt="Two different Azure DevOps PATs are used for SonarQube Server integration with Azure DevOps."><figcaption></figcaption></figure>

## Related pages <a href="#related-pages" id="related-pages"></a>

* [azure-pipelines-integration-overview](https://docs.sonarsource.com/sonarqube-server/devops-platform-integration/azure-devops-integration/azure-pipelines-integration-overview "mention")
* [setting-up-integration-at-global-level](https://docs.sonarsource.com/sonarqube-server/devops-platform-integration/azure-devops-integration/setting-up-integration-at-global-level "mention")
* [creating-your-project](https://docs.sonarsource.com/sonarqube-server/devops-platform-integration/azure-devops-integration/creating-your-project "mention")
* [setting-up-project-integration](https://docs.sonarsource.com/sonarqube-server/devops-platform-integration/azure-devops-integration/setting-up-project-integration "mention")
* [adding-analysis-to-pipeline](https://docs.sonarsource.com/sonarqube-server/devops-platform-integration/azure-devops-integration/adding-analysis-to-pipeline "mention")
* [troubleshooting-analysis](https://docs.sonarsource.com/sonarqube-server/devops-platform-integration/azure-devops-integration/troubleshooting-analysis "mention")
