Integration with Power BI in Power Pages

Completed

You can add a Power BI report or dashboard to a webpage in a Power Pages site to further extend the website as a powerful web application.

Before you can add a Power BI report to a Power Pages site, you need to enable the Power BI visualization or the Power BI Embedded Service in the Power Pages admin center.

Screenshot of the Power Pages admin center with Power BI Visualization and Power BI Embedded Service options highlighted.

  • Power BI Visualization - Allows you to embed publish to web Power BI reports for anonymous visitors or share Power BI reports or dashboards to Power BI Microsoft Entra ID authenticated users (for example, on an Employee self-service portal).
  • Power BI Embedded Service - Allows you to share the Power BI reports or dashboards to external users who don't have a Power BI license or Microsoft Entra ID authentication setup. This feature uses the new workspaces feature of Power BI. For more information, see Create a workspace in Power BI.

Enable Power BI visualization

Enabling Power BI visualization allows a Power Pages maker to add a Power BI component to a webpage and then set up the component to display a Power BI report or dashboard that's available for being published on the web. A report author needs to generate an embed code in the Power BI dashboard.

From the Power Pages design studio, you can add the Power BI component to a webpage. This action adds a Liquid tag to the webpage, which you can further edit and set up in the Visual Studio Code editor, depending on your specific requirements.

Screenshot of the add Power Pages components dialog with the Power BI component highlighted.

Parameters

The powerbi Liquid tag accepts the following parameters:

  • path - Path of the Power BI report or dashboard. If the Power BI report or dashboard is secure, you need to provide the authentication type.

    {% powerbi path:"https://app.powerbi.com/groups/00000000-0000-0000-0000-000000000000/reports/00000000-0000-0000-0000-000000000001/ReportSection01" %}
    
  • authentication_type - Type of authentication that's required for the Power BI report or dashboard. Valid values for this parameter for embedded Power BI visualizations are anonymous and aad (Microsoft Entra ID). The default value is anonymous. While adding the Power BI report or dashboard, ensure that it's shared with Microsoft Dataverse Microsoft Entra ID authenticated users.

    {% powerbi authentication_type:"aad" path:"https://app.powerbi.com/groups/00000000-0000-0000-0000-000000000000/reports/00000000-0000-0000-0000-000000000001/ReportSection01" %}
    
  • tileid - Displays the specified tile of the dashboard. You need to provide the ID of the tile.

    {% powerbi
       authentication_type:"aad"
       path:"https://app.powerbi.com/groups/00000000-0000-0000-0000-000000000000/dashboards/00000000-0000-0000-0000-000000000001"
       tileid:"00000000-0000-0000-0000-000000000002"
    %}
    

When a maker selects the Power BI component in the Power Pages design studio, they can set the values of the parameters by using the Power BI component dialog.

Screenshot of the Power BI component properties dialog.

You can also filter the report on one or more values by selecting Apply filter and then specifying the filter expression. For more information, see Filter a report by using query string parameters in the URL.

Important

Anonymous reports don't support filtering.

Filtering supports dynamic values, making it optimal for displaying personalized Power BI visualizations. You can also create a dynamic path and save it into a variable by using the capture Liquid tag, as shown in the following example:

{% capture pbi_path %}https://app.powerbi.com/groups/00000000-0000-0000-0000-000000000000/reports/00000000-0000-0000-0000-000000000001/ReportSection01?filter=Executives/Executive eq '{{user.id}}'{% endcapture %}
{% powerbi authentication_type:"aad" path:pbi_path %}

Before adding the Power BI report or dashboard to a webpage on a Power Pages website, you need to share it with the required users.

Screenshot example of a Power BI chart on a webpage.

Enable the Power BI Embedded service

You can also enable and set up the Power BI Embedded service feature within the Power Platform admin center.

When you enable the Power BI Embedded service, make sure that you specify the Power BI workspaces that are available for use on the website in the Power Platform admin center.

Screenshot of the enabled Power BI Embedded service with the link to edit workspaces highlighted.

When you activate the Power BI Embedded service, makers can embed Power BI reports on a webpage. This action takes advantage of the features and functionality of the Power BI Embedded service without makers needing to write corresponding code on the website. You need to create a workspace within Power BI and add the appropriate reports, dashboards, and tiles.

When you're adding an embedded Power BI report, specify if the audience is your customers (external users) or internal employees. Employees need to authenticate to the website by using Microsoft Entra ID. When you're adding a report for external users, set the value of authentication_type to powerbiembedded, as shown in the following example:

{% powerbi authentication_type:"powerbiembedded" path:"https://app.powerbi.com/groups/00000000-0000-0000-0000-000000000000/reports/00000000-0000-0000-0000-000000000001/ReportSection01" %}

You can also set the correct authentication type by setting Access type to Embed for your customers in the property dialog.

Screenshot of a Power BI component dialog set up to display a report for an external audience.

Note

Power BI sharing requires appropriate licensing. Licensing requirements depend on the audience and the method of sharing.

For more information on setting up Power BI integration, see Set up Power BI integration.

For more information on sharing and licensing requirements, see Share Power BI workspace and Share Power BI dashboard and report.