> For the complete documentation index, see [llms.txt](https://docs.sonarsource.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.sonarsource.com/sonarqube-server/quality-standards-administration/managing-quality-profiles/understanding-quality-profiles.md).

# Understanding quality profiles

Quality profiles are a key part of your SonarQube Server 2026.5 configuration because they are composed of a list of rules to check your code against.

## Quality profile set assigned to a language <a href="#quality-profile-set-assigned-to-a-language" id="quality-profile-set-assigned-to-a-language"></a>

Several quality profiles can be assigned to a language:

* Three built-in Sonar way profiles are provided at installation: **Sonar way core**, **Sonar way extended**, and **Sonar way comprehensive**. You cannot edit these profiles. See [Built-in quality profiles](/sonarqube-server/quality-standards-administration/managing-quality-profiles/built-in-quality-profiles.md) for details on each.
* You can create custom quality profiles to meet your coding analysis needs.\
  Sonar way core is designed to be broadly suitable for most projects, but it is intended only as a starting point.

In the quality profile set of a language, a profile is defined as the default profile. The default profile is used for the analysis of a project if no profile is explicitly defined for that project.

<figure><img src="https://4213461411-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmX1WoFEHhJp6VdSbyTDi%2Fuploads%2Fgit-blob-3a5b13390f92d20e3406469616b119ba70d76d0d%2Fsonarqube-server-default-quality-profile.png?alt=media" alt="Quality profiles page filtered by Java, listing Sonar way core as the default built-in profile, plus three other built-in profiles."><figcaption></figcaption></figure>

A user with the Administer Quality Profiles permission can create and edit any custom profile and change the default profile of a set. These users can also give other users permission to edit a given custom profile.

## Quality profile definition <a href="#quality-profile-definition" id="quality-profile-definition"></a>

A quality profile:

* Relates to a given programming language.
* Is based on the set of coding rules supported for this language.
* Defines which rules of this set are active in the profile, it means which rules will be taken into account during the code analysis.

A custom quality profile may customize, for a given rule, the following parameters:

* Severity level(s).
* When applicable: configurable rule parameters.\
  For example, rules that verify conditions against a threshold might allow customization of the threshold value.

The customization applies only within the quality profile. In particular, it will not change the rule’s recommended severity levels on the **Rules** platform.

In addition, from the [Enterprise edition](https://www.sonarsource.com/plans-and-pricing/enterprise/), rules can be marked as Prioritized in a quality profile. Prioritized rules are used to fail the quality gate when the corresponding prioritized issues are raised in the overall code.

## Quality profile inheritance <a href="#quality-profile-inheritance" id="quality-profile-inheritance"></a>

The inheritance feature allows you to define a parent/child relationship between two quality profiles within the profile set of a language. This way, changes in the parent profile are dynamically reported to the child profile. Note that a child profile can only be a custom quality profile.

<figure><img src="https://4213461411-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmX1WoFEHhJp6VdSbyTDi%2Fuploads%2Fgit-blob-620b0aeb440e9fa37cc393fef8a42110ea838152%2Fsonarqube-server-child-quality-profile.png?alt=media" alt="Quality profiles page filtered by Java, showing a custom Sonar way core child profile nested under the built-in Sonar way core default profile."><figcaption></figcaption></figure>

By inheriting from a built-in quality profile, you ensure that you automatically benefit from:

* Newly implemented rules.
* Changes in a rule’s configuration.
* The deactivation of deprecated rules.

You can also create a quality profile hierarchy: a change in a parent profile is reflected in all its child profiles on all hierarchy levels.

The following principles govern the quality profile inheritance:

* The inheritance relationship can be established or removed according to the following:
  * A parent profile can be assigned to a child profile during the child profile creation or at any time during the lifecycle of a custom profile.
  * The inheritance relationship can be removed at any time.
  * A child profile can change to another parent at any time.
  * A parent profile may be a built-in or a custom profile (A child profile is always a custom profile.).
* When an inheritance relationship is established:
  * The child quality profile inherits its parent’s active rules.
  * Active rules existing already in the child profile are not changed.
* A change in a parent profile is automatically reflected in all its child profiles (note that if a child profile changes to another parent, this is considered a change in the parent profile). It means that:
  * A rule activation or deactivation in the parent profile is reflected in the child profiles whatever the status (active or inactive) of the rule in the child profile.
  * A rule parameter change in the parent profile is reflected in the child profiles if the rule is not overridden in the child profile.
* A child quality profile can be changed as follows:
  * An inactive rule can be activated.
* If enabled at the global level, an active rule can be deactivated.
* A rule’s severity level(s) or configurable parameters can be modified compared to the parent profile. In that case, the rule is considered *overridden*.

{% hint style="info" %}
The principles described above are the same whether the parent profile is a built-in or a custom profile.
{% endhint %}

{% hint style="info" %}
If Sonar updates the rules set of a language (for instance, by adding or changing a rule) and/or the respective built-in quality profile, this update will be available in your SonarQube once you have upgraded it.
{% endhint %}

## Quality profile association with projects <a href="#quality-profile-association-with-projects" id="quality-profile-association-with-projects"></a>

The default quality profile of a language’s profile set is used for a project if the project is not explicitly associated with another profile for this language.

By default, **Sonar way core** is the default profile for every language. With the Administer Quality Profiles permission, you can change the default profile of a given language.

As a project administrator, you can assign quality profiles to your project. With the Administer Quality Profiles permission, you can assign a quality profile to a list of projects.

## Quality profiles for compliance standards

As Sonar expands its offering, specialized quality profiles for enterprise-level customers are being developed to address the needs of specific industries.

### The Sonar MISRA compliance quality profiles <a href="#sonar-misra-compliance" id="sonar-misra-compliance"></a>

The **Sonar MISRA compliance** quality profiles are available in [Enterprise edition](https://www.sonarsource.com/plans-and-pricing/enterprise/) and above. They comprise the following quality profiles:

* Sonar MISRA C++:2023 Compliance
* Sonar MISRA C:2012 Compliance
* Sonar MISRA C:2012 AMD1 + TC1 Compliance
* Sonar MISRA C:2012 AMD2 Compliance
* Sonar MISRA C:2012 AMD3 Compliance
* Sonar MISRA C:2023 Compliance

These quality profiles check your code against a set of software development guidelines for the C or C++ programming languages used in safety and mission-critical systems. MISRA guidelines are published by the [MISRA](https://misra.org.uk/) (Motor Industry Software Reliability Association) consortium. The standards aim to facilitate code safety, security, portability, and reliability. Read [The intelligent approach to achieve MISRA C++:2023 compliance](https://www.sonarsource.com/blog/achieve-misra-c-2023-compliant-source-code/) blog post on the Sonar website for more information.

The **Sonar MISRA compliance** quality profiles are their own built-in profiles, separate from Sonar way core, extended, and comprehensive. None of the three Sonar way profiles cover MISRA. Each Sonar MISRA compliance profile combines Sonar rules mapped one-to-one to the matching MISRA guidelines, to provide both Sonar and MISRA expertise in one quality profile.

You can use these quality profiles as a starting point for your own custom quality profile by adding or removing rules. If you want to create a quality profile only with MISRA rules, you can start one from scratch and add all rules carrying a `misra-` tag to it. See [Editing a quality profile](/sonarqube-server/quality-standards-administration/managing-quality-profiles/editing-a-custom-quality-profile.md) for more information.

MISRA and MISRA C are the registered trade marks of [The MISRA Consortium Limited](https://misra.org.uk/).

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

* [Built-in quality profiles](/sonarqube-server/quality-standards-administration/managing-quality-profiles/built-in-quality-profiles.md)
* [Viewing quality profiles](/sonarqube-server/quality-standards-administration/managing-quality-profiles/viewing-quality-profiles.md)
* [Creating a quality profile](/sonarqube-server/quality-standards-administration/managing-quality-profiles/creating-a-quality-profile.md)
* [Editing a quality profile](/sonarqube-server/quality-standards-administration/managing-quality-profiles/editing-a-custom-quality-profile.md)
* [Associating with projects](/sonarqube-server/quality-standards-administration/managing-quality-profiles/associating-a-quality-profile-with-projects.md)
* [Changing default quality profile](/sonarqube-server/quality-standards-administration/managing-quality-profiles/changing-default-quality-profile.md)
* [Maintaining quality profiles](/sonarqube-server/quality-standards-administration/managing-quality-profiles/maintaining-your-custom-quality-profiles.md)
* [Granting permissions to users](/sonarqube-server/quality-standards-administration/managing-quality-profiles/authorizing-other-users-to-manage-quality-profile.md)
* [Changing your project's quality profiles](/sonarqube-server/project-administration/adjusting-analysis/changing-quality-gate.md)
* [Quality profiles for agentic AI](/sonarqube-server/quality-standards-administration/ai-code-assurance/quality-profiles-for-agentic-ai.md)

## Related online learning

* <i class="fa-desktop">:desktop:</i> [Introduction to rules, quality profiles, and quality gates in SonarQube](https://www.sonarsource.com/learn/course/core-concepts/4ce5a772-5253-41dd-b521-8f7c72a7c6dd/introduction-to-rules-quality-profiles-and-quality-gates-in-sonarqube)
* <i class="fa-video">:video:</i> [Administering quality profiles in SonarQube](https://www.sonarsource.com/learn/course/core-concepts/99c287ee-6671-471d-b6ff-4ec88be61383/administering-quality-profiles-in-sonarqube)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.sonarsource.com/sonarqube-server/quality-standards-administration/managing-quality-profiles/understanding-quality-profiles.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
