---
title: "Cross-dashboard variables | Grafana documentation"
description: "Add variables that you can use across dashboards, globally or by folder."
---

> For a curated documentation index, see [llms.txt](/llms.txt). For the complete documentation index, see [llms-full.txt](/llms-full.txt).

This is documentation for the **next** version of Grafana documentation. For the latest stable release, go to the [latest version](/docs/grafana/latest/).

[Documentation](/docs/)![breadcrumb arrow](/static/assets/img/icons/grafana-icon-breadcrumb-arrow-gray.svg) [Grafana documentation](/docs/grafana/next/)![breadcrumb arrow](/static/assets/img/icons/grafana-icon-breadcrumb-arrow-gray.svg) [Visualize data](/docs/grafana/next/visualizations/)![breadcrumb arrow](/static/assets/img/icons/grafana-icon-breadcrumb-arrow-gray.svg) [Dashboards](/docs/grafana/next/visualizations/dashboards/)![breadcrumb arrow](/static/assets/img/icons/grafana-icon-breadcrumb-arrow-gray.svg) [Variables](/docs/grafana/next/visualizations/dashboards/variables/)![breadcrumb arrow](/static/assets/img/icons/grafana-icon-breadcrumb-arrow-gray.svg) Cross-dashboard variables

Grafana Cloud Enterprise Open source

> Note
> 
> Cross-dashboard variables is currently in [public preview](/docs/release-life-cycle/). Grafana Labs offers limited support, and breaking changes might occur prior to the feature being made generally available.
> 
> To use this feature, enable the `grafana.dashboardGlobalVariables` feature toggle in your Grafana configuration file or contact Support.

Unlike variables that are specific to the dashboard in which you build them, you can create *cross-dashboard variables* for use across multiple dashboards. These variables help ensure consistent naming across your organization and eliminate the need to re-create the same variables every time you add a new dashboard.

You can scope cross-dashboard variables in two ways:

- **Globally**: Available to all dashboards in the organization.
- **By folder**: Available only to the dashboards in the same folder as the variable.

The **Dashboards &gt; Variables** page lists cross-dashboard variables, showing which ones are available globally or by folder. In the following image, there are variables in “Core metrics” and “Grafana Cloud” folders and then a number of variables that aren’t in any folders; these ones are global:

When you add cross-dashboard variables to a dashboard, only the ones that share the same scope as your dashboard are available for you to select.

For example, in the preceding image, there are two variables in the “Core metrics” folder. The following image shows a dashboard in the “Core metrics” folder. As a result, the variables in the “Core metrics” folder are available to that dashboard, as well as all the global variables:

Variables in other folders aren’t available to that dashboard.

## Create cross-dashboard variables

To create cross-dashboard variables, follow these steps:

1. Navigate to **Dashboards &gt; Variables**.
2. Click **+ New variable**.
3. Set the following general variable properties:
   
   Expand table
   
   OptionDescription
   
   FolderSet the availability of the variable. To allow the variable to be used in all of the organization’s dashboards, select **Dashboards**.
   
   Variable typeChoose a variable type.
   
   NameEnter a name for the variable.
   
   Label(Optional) Enter the display name for the variable drop-down list. If you leave this empty, then the variable name is used.
   
   Description
   
   (Optional) Enter a description of the variable. When you add a description, an info icon appears next to the variable name on the dashboard. Hover your cursor over the icon to display the description.
   
   Descriptions support links. You can use Markdown-style links like `[link text](https://example.com)`, or paste bare URLs like `https://example.com`. Only `http` and `https` URLs render as clickable links—other protocols display as plain text.
   
   DisplayChoose where the variable displays:
   
   - **Above dashboard**: The variable drop-down list displays above the dashboard with the variable **Name** or **Label** value. This is the default.
   - **Above dashboard, label hidden**: The variable drop-down list displays above the dashboard, but without showing the name of the variable.
   - **Controls menu**: The variable displays in the dashboard controls menu instead of above the dashboard. The dashboard controls menu appears as a button in the dashboard toolbar.
   - **Hidden**: No variable drop-down list displays on the dashboard.
4. Click one of the following links to complete the steps for adding your selected variable type:
   
   - [Query](/docs/grafana/next/visualizations/dashboards/variables/add-template-variables/#add-a-query-variable)
   - [Custom](/docs/grafana/next/visualizations/dashboards/variables/add-template-variables/#add-a-custom-variable)
   - [Textbox](/docs/grafana/next/visualizations/dashboards/variables/add-template-variables/#add-a-text-box-variable)
   - [Constant](/docs/grafana/next/visualizations/dashboards/variables/add-template-variables/#add-a-constant-variable)
   - [Data source](/docs/grafana/next/visualizations/dashboards/variables/add-template-variables/#add-a-data-source-variable)
   - [Interval](/docs/grafana/next/visualizations/dashboards/variables/add-template-variables/#add-an-interval-variable)
   - [Switch](/docs/grafana/next/visualizations/dashboards/variables/add-template-variables/#add-a-switch-variable)

## Add cross-dashboard variables to a dashboard

You can choose which cross-dashboard variables to add to dashboards you create. Only variables that share the same scope as your dashboard are available for you to select.

To add cross-dashboard variables to a dashboard, follow these steps:

1. Navigate to the dashboard you want to update.
2. Click **Edit**.
3. Click the **Add new element** icon in the sidebar and select **Variable**.
   
   You can also click the **Add** (plus sign) icon at the top of the dashboard and select **Variable**.
4. Select the **Global or folder variable** variable type.
5. Select the variables you want to add to the dashboard:
   
   To add every global variable available, select **All global** and to add every folder variable available, select **All folder**.
6. Update variable values as needed.
7. Click **Save**.
8. Enter an optional description of your changes and click **Save**.
9. Click **Exit edit**.

After you’ve added cross-dashboard variables to a dashboard, you can view its settings or remove it by way of the dashboard sidebar. To edit the variable, go to **Dashboards &gt; Variables**.
