> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Connecting Grafana to Insights

> Connect Grafana to legacy PlayFab Insights, add a data source, and build dashboards that run Kusto queries on your game telemetry for monitoring and alerts.

# Tutorial: Connecting Grafana to Insights

This guide helps you get started using Grafana along with Insights. After connecting, you can use Grafana to run analytics and monitoring systems on your game data from Insights. To learn more about other tools you can connect Insights with, see [Connecting external tools to Insights](/services/playfab/data-analytics/legacy/connectivity).

In this tutorial you learn how to:

<Note>
  \[!div class="checklist"] \* Set up Grafana for Insights \* Create a data source in Grafana \* Create a dashboard in Grafana \* Run Kusto queries and commands using the dashboard
</Note>

<Note>
  PlayFab Insights Management was retired on 3/31/2026. We recommend using [Azure Data Explorer (ADX) Connections](/services/playfab/data-analytics/export-data/data-connection-adx) to manage your performance and cost going forward. If your title is still using **Insights**, continue to see this article for implementation details. For more information, see [PlayFab Digest: March feature updates](https://developer.microsoft.com/en-us/games/articles/2026/04/playfab-digest-march-feature-updates/).
</Note>

## Prerequisites

### PlayFab account authenticated with Microsoft Entra ID

You need a PlayFab account or user for which the authentication provider is set to Microsoft. The Microsoft authentication provider uses Microsoft Entra ID (previously Azure Active Directory (AAD)) for authentication that is required to use the Azure services. See [Azure Active Directory Authentication for Game Manager](/services/playfab/identity/dev-identity/authentication/aad-authentication) for instructions on creating an Microsoft Entra ID authenticated account or user.

To verify that the account, or user, is set to use the Microsoft authentication provider:

* Visit [developer.playfab.com](https://developer.playfab.com).
* Select **Sign in with Microsoft** to access your PlayFab account.

If you can sign in, then the account is set to use the Microsoft authentication provider.

### Game Manager permissions for Insights

You need to assign your account a [user role](/services/playfab/identity/dev-identity/permissions/playfab-user-roles) with the following Game Manager permissions enabled:

* Admin status.
* Access to the Explorer tab and associated data.
* Read and write access to Analytics data.

You can either create a new user role or add these permissions to an existing role.

### Other prerequisites

* [Create a Microsoft Entra ID application and connect it to your title database](/services/playfab/data-analytics/legacy/connectivity/creating-AAD-app-for-insights)

## Get set up with Grafana

1. There are two ways to get Grafana. You can [create a free account](https://grafana.com/login) and download Grafana to run on your computer. Or, if you have a paid Grafana Cloud subscription, you can use your online hosted instance.
2. Install the [Azure Data Explorer](https://grafana.com/grafana/plugins/grafana-azure-data-explorer-datasource) plugin for Grafana.

## Create a new data source in Grafana

Now that your title database is linked to an Azure app, you can use the app to connect with Grafana. To create a new data source:

1. Log in to Grafana.
2. On the **Welcome to Grafana** page, select **Add data source**.
3. On the **Add Datasource** page, select the **Azure Data Explorer Datasource**. You can search for it with the search bar or find it listed under the section **Others**. If you don't see the **Azure Data Explorer Datasource** option, you need to install the Azure Data Explorer Datasource For Grafana plugin. <img src="https://mintcdn.com/microsoft-4404708b/MjJ0-cTsb1bpaMcX/images/playfab/data-analytics/legacy/connectivity/grafana-add-datasource.png?fit=max&auto=format&n=MjJ0-cTsb1bpaMcX&q=85&s=308a78625124cecfa0190ffa2a6d902f" alt="Grafana Add Datasource" width="1465" height="615" data-path="images/playfab/data-analytics/legacy/connectivity/grafana-add-datasource.png" />
4. On the **Azure Data Explorer Datasource** configuration page:
   * For **Cluster URL**, enter the PlayFab API endpoint, which is `https://insights.playfab.com`.
   * Enter your **Tenant Id**, **Client Id**, and **Client secret** from your Microsoft Entra ID application into their respective fields.
   * Select **Save & Test**. You should see a **Connection Successful** return message.
   * From **Default Database**, select your Title ID or database name. This field automatically populates after you successfully save and test the datasource. If it doesn't show up after a successful connection, try exiting and reopening the configuration page. <img src="https://mintcdn.com/microsoft-4404708b/MjJ0-cTsb1bpaMcX/images/playfab/data-analytics/legacy/connectivity/grafana-datasource-configuration.png?fit=max&auto=format&n=MjJ0-cTsb1bpaMcX&q=85&s=7fe6afaa1c39f94ac85d74cddaab1fb3" alt="Grafana Datasource Configuration" width="1586" height="707" data-path="images/playfab/data-analytics/legacy/connectivity/grafana-datasource-configuration.png" />

## Create a dashboard

From the Grafana homepage we'll create a new dashboard. To create a dashboard:

1. Select **New dashboard**. <img src="https://mintcdn.com/microsoft-4404708b/MjJ0-cTsb1bpaMcX/images/playfab/data-analytics/legacy/connectivity/grafana-new-dashboard.png?fit=max&auto=format&n=MjJ0-cTsb1bpaMcX&q=85&s=ee1ccd38c312c481a7e6d1e3853814e3" alt="Grafana New Dashboard" width="1534" height="333" data-path="images/playfab/data-analytics/legacy/connectivity/grafana-new-dashboard.png" />
2. In the **New Panel** dialog box, select **Add Query**. <img src="https://mintcdn.com/microsoft-4404708b/MjJ0-cTsb1bpaMcX/images/playfab/data-analytics/legacy/connectivity/grafana-new-panel.png?fit=max&auto=format&n=MjJ0-cTsb1bpaMcX&q=85&s=0ce9eb2fe67f337040ec2ec4d003d3c5" alt="Grafana New Panel" width="829" height="503" data-path="images/playfab/data-analytics/legacy/connectivity/grafana-new-panel.png" />
3. In the **Query** panel next to **Database**, select your database from the drop-down menu. In this example the database name is **Unicorn Battle**. <img src="https://mintcdn.com/microsoft-4404708b/MjJ0-cTsb1bpaMcX/images/playfab/data-analytics/legacy/connectivity/grafana-new-query.png?fit=max&auto=format&n=MjJ0-cTsb1bpaMcX&q=85&s=6e1cc311d6f82ec40188249d889ac2f2" alt="Grafana New Query" width="1623" height="549" data-path="images/playfab/data-analytics/legacy/connectivity/grafana-new-query.png" />

## Run Kusto queries and commands

Now you're going to use your newly created Dashboard to run Kusto queries and commands on your database. To run a query:

1. In the **Query** panel next to **Format As**, select **Table** from the drop-down menu. <img src="https://mintcdn.com/microsoft-4404708b/MjJ0-cTsb1bpaMcX/images/playfab/data-analytics/legacy/connectivity/grafana-table-format.png?fit=max&auto=format&n=MjJ0-cTsb1bpaMcX&q=85&s=15b7b1dc9f43ee66429f41189838af0e" alt="Grafana Table Format" width="2200" height="751" data-path="images/playfab/data-analytics/legacy/connectivity/grafana-table-format.png" />
2. Use the icons on the left to switch to the Visualization panel. Select the drop-down menu to the right of **Visualization**, then select the **Table** option. <img src="https://mintcdn.com/microsoft-4404708b/MjJ0-cTsb1bpaMcX/images/playfab/data-analytics/legacy/connectivity/grafana-table-visualization.png?fit=max&auto=format&n=MjJ0-cTsb1bpaMcX&q=85&s=3de1502c1bf2f8673833c3a2345be6e7" alt="Grafana Table Visualization" width="2011" height="672" data-path="images/playfab/data-analytics/legacy/connectivity/grafana-table-visualization.png" />
3. Return to the **Query** tab. Enter a query and select **Run**. The results appear in the table above the **Query** tab. In this example, we ran the query `['events.all'] | limit 100`. <img src="https://mintcdn.com/microsoft-4404708b/MjJ0-cTsb1bpaMcX/images/playfab/data-analytics/legacy/connectivity/grafana-run-query.png?fit=max&auto=format&n=MjJ0-cTsb1bpaMcX&q=85&s=fd1c90e47b834a11c7d7cb4c6e9c0540" alt="Grafana Run Query" width="2253" height="1005" data-path="images/playfab/data-analytics/legacy/connectivity/grafana-run-query.png" /> Running a Kusto command follows the same process. Enter your command in the **Query** tab and select **Run**. The results are displayed above. In this example, we ran the command `.show tables`. <img src="https://mintcdn.com/microsoft-4404708b/MjJ0-cTsb1bpaMcX/images/playfab/data-analytics/legacy/connectivity/grafana-run-command.png?fit=max&auto=format&n=MjJ0-cTsb1bpaMcX&q=85&s=8aa9b399068f41b749546d148fead7bc" alt="Grafana Run Command" width="2254" height="1057" data-path="images/playfab/data-analytics/legacy/connectivity/grafana-run-command.png" />

## More resources

* [Grafana documentation](https://grafana.com/docs/grafana/latest/)
* To learn about other tools to connect to Insights, see  [Connecting external tools to Insights](/services/playfab/data-analytics/legacy/connectivity).


## Related topics

- [Connecting external tools with Insights](/services/playfab/data-analytics/legacy/connectivity/index.md)
- [Connecting Python to Insights](/services/playfab/data-analytics/legacy/connectivity/connecting-python-to-insights.md)
- [Connecting Kusto C# SDK to Insights](/services/playfab/data-analytics/legacy/connectivity/connecting-kusto-csharp-to-insights.md)
- [Connecting Kusto Explorer to Insights](/services/playfab/data-analytics/legacy/connectivity/connecting-kusto-explorer-to-insights.md)
- [Connecting Power BI to Insights](/services/playfab/data-analytics/legacy/connectivity/connecting-power-bi-to-insights.md)
