> 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-cloud/managing-your-projects/dashboards/creating-dashboards.md).

# Creating dashboards

This feature is available in the [Enterprise](https://www.sonarsource.com/plans-and-pricing/sonarcloud/) plan.

There are two ways to create a custom dashboard: duplicate an existing dashboard or create one from scratch.

## Duplicating an existing dashboard

You can duplicate an existing dashboard and use it as a starting point. Sometimes, this is the fastest way to get started.

<figure><img src="/files/rCKaHS0pgpmdPh1S0hls" alt="duplicating a dashboard on All dashboards page"><figcaption></figcaption></figure>

1. Retrieve your project. See [Retrieving projects](/sonarqube-cloud/managing-your-projects/retrieving-projects.md) for more information.
2. Go to **Dashboards**. The **Dashboards** page opens and lists all available dashboards.
3. Click the action menu next to the existing dashboard and select **Duplicate**. You can only duplicate custom dashboards.
4. In the **Duplicate dashboard** modal, enter the dashboard name and description, then click **Create duplicate**. The new dashboard appears on the **Dashboards** page.
5. Click the action menu next to the duplicated dashboard and select **Edit dashboard** to customize it.

## Creating a custom dashboard from scratch

<figure><img src="/files/ziZ1RjDVAUWDFfdNEjMQ" alt="Creating a new custom dashboard"><figcaption></figcaption></figure>

To create a custom dashboard from scratch:

1. Retrieve your project. See [Retrieving projects](/sonarqube-cloud/managing-your-projects/retrieving-projects.md) for more information.
2. Go to **Dashboards**.
3. Click the **Create custom dashboard** button in the top-right corner.
4. In the **Create custom dashboard** modal, enter the dashboard name and description, then click **Create**. The new dashboard appears on the **Dashboards** page.
5. Click the action menu next to the new dashboard and select **Edit dashboard** to customize it.

In edit mode, you can use the following options at the top of the page:

<figure><img src="/files/McvIeOAiIYAU9HqvsEK2" alt="Dashboards editing options"><figcaption></figcaption></figure>

* **Add widget**: Opens a modal where you can configure the widget. See [#adding-a-widget](#adding-a-widget "mention") for details.
* **Add section**: Sections group a set of widgets together and are collapsible. See [#adding-a-section](#adding-a-section "mention") for details.
* **Cancel and exit**: Exits edit mode without saving changes.
* **Save changes**: Saves your changes.

## Adding a widget

In the dashboard’s edit mode, click **Add widget** to open a modal. In the **Add new widget** modal, follow these steps:

<div align="left"><figure><img src="/files/wJlv7qgJ7Z2obNYXCGMm" alt="Configuring a new widget"><figcaption></figcaption></figure></div>

### Step 1: Define your widget

* **Visualization**: Choose the visualization that represents the data. The options are **Count**, **Badge**, **Line chart**, **Donut chart**, **Pie chart,** and **Top list**. See [Viewing and managing dashboards](/sonarqube-cloud/managing-your-projects/dashboards/viewing-and-managing-dashboards.md#viewing-dashboards) for more information about the chart options.
* **Metric**: Choose the metric you want to visualize. The metric drop-down list is filtered by the metrics available for the visualization you selected. See [#metrics](#metrics "mention") for a list of available metrics and associated visualizations.
* **Slice by**: This option appears only for pie and donut charts. Available options depend on the metric you have chosen.

### Step 2: Apply filters

Depending on the metric you have selected in the previous step, appropriate filters are displayed. Feel free to explore the filters and combine them with various metrics to find the desired results.

* **Scope**: For the count, rating badge, pie, and donut chart visualizations, you can choose between **Overall code** or **New code**. For the line chart, **Overall code** is the only option and is applied by default.
* **Time range**: This option appears only for the line chart because it is a time-based chart. The options are: **All**, **Last 3 months**, and **Last month**.
* Additional filters appear that are relevant to the visualization and metric you selected in the previous step.

### Step 3: Customize visualization

* **Show legend**: Select this option to display a legend for a visualization. This applies to line, donut, and pie charts.
* **Show trend indicator**: Available only for the count visualization.

Once you are done configuring the widget:

* Click **Add to dashboard** at the bottom of the modal.
* Click **Save changes** at the top of the dashboard page, if you are done editing.

## Adding a section

Sections help you organize and group your widgets on a dashboard.

To create a section:

* Enter edit mode and click **Add section** to open a modal.
* Enter the section name and description in the modal.
* Click **Create section** to add it to the dashboard.

<figure><img src="/files/0I8joAE4FyGnyKV50MPz" alt="Options for a section element"><figcaption></figcaption></figure>

1. Once the section appears on the dashboard, you can move it by clicking the handle in the upper-left corner and dragging it to another location.
2. Click **Add widget** to add a new widget directly from within the section.
3. Click the action menu located in the upper right corner of the section to edit or delete the section.
4. **Collapse** or **Expand** the section to change its visibility. This feature works even after you save the changes and exit edit mode.
5. Click **Save changes** at the top of the page when you are done.

## Metrics

The following table shows a list of metrics and associated visualizations.

| Metrics                                           | Visualization                                                      | Additional information                                                                                                                                                                                                                                  |
| ------------------------------------------------- | ------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **Issues**                                        |                                                                    |                                                                                                                                                                                                                                                         |
| Issue count                                       | Count, line and multi-line chart, donut chart, pie chart, top list | Shows the number of issues in all states. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#issues)                                                                                                |
| Issue density                                     | Count, line chart                                                  | Shows the number of issues per 1000 lines of code. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#issues)                                                                                       |
| Closed issues                                     | Count, line chart                                                  | Shows the number of issues that no longer appear in a later analysis. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#issues)                                                                    |
| Mean time to resolve (MTTR) issues                | Count, line chart                                                  | Shows the average time between an issue being detected and resolved. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#issues)                                                                     |
| Mean time to resolve (MTTR) newly detected issues | Count, line chart                                                  | Shows the average time between an issue being detected and resolved, within 30 days. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#issues)                                                     |
| **Security**                                      |                                                                    |                                                                                                                                                                                                                                                         |
| Security remediation effort                       | Count, line chart                                                  | Shows the effort to fix all vulnerabilities. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#security)                                                                                           |
| Security hotspots                                 | Count, line chart                                                  | Shows the number of security hotspots. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#security-review)                                                                                          |
| Security hotspots reviewed                        | Count, line chart                                                  | Shows the percentage of security hotspots that have been reviewed. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#security-review)                                                              |
| Security hotspot count                            | Donut chart, pie chart                                             | Shows the number of security hotspots. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#security-review)                                                                                          |
| Security rating                                   | Badge                                                              | Rating related to security. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#security)                                                                                                            |
| Security review rating                            | Badge                                                              | Rating based on the percentage of reviewed security hotspots. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#security-review)                                                                   |
| **Reliability**                                   |                                                                    |                                                                                                                                                                                                                                                         |
| Reliability remediation effort                    | Count, line chart                                                  | Shows the effort to fix all reliability issues. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#reliability)                                                                                     |
| Reliability rating                                | Badge                                                              | Rating related to reliability. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#reliability)                                                                                                      |
| **Maintainability**                               |                                                                    |                                                                                                                                                                                                                                                         |
| Effort to reach maintainability rating A          | Count, line chart                                                  | Shows the effort required to reach maintainability rating A. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#maintainability)                                                                    |
| Technical debt ratio                              | Count, line chart                                                  | Shows the ratio between the cost to develop the software and the cost to fix it. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#maintainability)                                                |
| Technical dept ratio of new/changed code          | Count, line chart                                                  | Shows the technical debt ratio for new code. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#maintainability)                                                                                    |
| Maintainability rating                            | Badge                                                              | Rating related to the value of the technical debt ratio. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#maintainability)                                                                        |
| **Coverage**                                      |                                                                    |                                                                                                                                                                                                                                                         |
| Conditions to cover                               | Count, line chart                                                  | Shows the number of conditions that could be covered by unit tests. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#coverage)                                                                    |
| Coverage by tests                                 | Count, line chart                                                  | Shows a mix of line coverage and condition coverage. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#coverage)                                                                                   |
| Line coverage                                     | Count, line chart                                                  | Shows the percentage of lines covered by unit tests. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#coverage)                                                                                   |
| Lines to cover                                    | Count, line chart                                                  | Shows the number of lines of code that could be covered by unit tests. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#coverage)                                                                 |
| Uncovered conditions                              | Count, line chart                                                  | Shows the number of conditions that are not covered by unit tests. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#coverage)                                                                     |
| Uncovered lines                                   | Count, line chart                                                  | Shows the number of lines of code that are not covered by unit tests. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#coverage)                                                                  |
| **Duplications**                                  |                                                                    |                                                                                                                                                                                                                                                         |
| Duplicated blocks                                 | Count, line chart                                                  | Shows the number of duplicated blocks of lines. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#duplications)                                                                                    |
| Duplicated files                                  | Count, line chart                                                  | Shows the number of files involved in duplications. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#duplications)                                                                                |
| Duplicated lines                                  | Count, line chart                                                  | Shows the number of lines involved in duplications. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#duplications)                                                                                |
| Duplicated lines density                          | Count, line chart                                                  | Shows the percentage of duplicated lines. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#duplications)                                                                                          |
| **Size**                                          |                                                                    |                                                                                                                                                                                                                                                         |
| Comment lines                                     | Count, line chart                                                  | Shows the number of lines containing either a comment or commented-out code. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#size)                                                               |
| Comment lines density                             | Count, line chart                                                  | Shows the percentage of comment lines. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#size)                                                                                                     |
| Lines                                             | Count, line chart                                                  | Shows the number of physical lines. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#size)                                                                                                        |
| Line count                                        | Donut chart, pie chart                                             | Shows the number of physical lines. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#size)                                                                                                        |
| **Dependency risks**                              |                                                                    |                                                                                                                                                                                                                                                         |
| Dependency risks                                  | Count, line chart                                                  | Shows the total number of dependency risks found in your project or portfolio. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#sca)                                                              |
| Dependency security risks                         | Count, line chart                                                  | Shows total dependency risks that affect security, such as vulnerable or malicious packages. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#sca)                                                |
| Vulnerable dependency risks                       | Count, line chart                                                  | Shows total third-party packages with a publicly reported vulnerability. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#sca)                                                                    |
| Malicious package dependency risks                | Count, line chart                                                  | Shows total third-party packages known to be malicious. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#sca)                                                                                     |
| Prohibited license dependency risks               | Count, line chart                                                  | Shows total packages whose license is not allowed by your organization’s license policy. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#sca)                                                    |
| Dependency risk rating                            | Badge                                                              | Rating related to dependency risks. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#sca)                                                                                                         |
| Mean time to resolve (MTTR) for dependency risks  | Count, line chart                                                  | Shows the average time to resolve dependency risks in the last 30 days. It includes risks that are fixed or marked safe during that period. See [Understanding measures and metrics](/sonarqube-cloud/managing-your-projects/metric-definitions.md#sca) |

Dashboards include metrics related to dependency risks. To view dependency risks, you need access to SonarQube Advanced Security. See [Subscribing to the Advanced Security product](/sonarqube-cloud/administering-sonarcloud/managing-subscription/signing-up-for-plan.md#advanced-security) for signup instructions.

## Related pages

* [Viewing and managing dashboards](/sonarqube-cloud/managing-your-projects/dashboards/viewing-and-managing-dashboards.md)


---

# 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 dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.sonarsource.com/sonarqube-cloud/managing-your-projects/dashboards/creating-dashboards.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
