In this Power Bi tutorial, we will learn how to embed Power bi report in SharePoint Online. There are different ways, we can embed power bi in sharepoint.
The different ways to embed power bi in SharePoint or publish power bi to sharepoint:
- Embed power bi report in sharepoint Online using Embed Link (using Power BI web part)
- Integrate power bi report to SharePoint online using Power BI report URL (using Power BI web part)
- Embed power bi report to SharePoint Online using embed code
- embed power bi report in classic SharePoint page
- How to fix the error, Contact your admin to enable embed code creation in Power BI
- How to enable publish to web option in Power bi
In SharePoint Online, we can embed Power Bi report using Embed link, Power BI report web part, and using embed code.
Now we will see how to embed the power bi report in SharePoint Online by using the Power Bi web part. Here we are using sample data to create a power bi report by using this sample data.
- Open your Power bi desktop
- Load the data using Get data present in the ribbon of power bi.
- Then go to Report in Power Bi Desktop.
- Here I have created the visualization using a Stacked column chart, pie chart, card, and Line chart.
- Click on the publish present in the ribbon in power bi.
- After successful publishing, you can open the power bi service directly on the web using app.powerbi.com.
- Click on My workspace-> Reports present in the navigation in power bi service.
- Under reports click on the Finance report.
- Click on the File menu -> click on the Embed Report -> select SharePoint Online.
- Copy the Embed Link of the report in power bi.
- Open the SharePoint Online site in which site you want to embed the link.
- On the Home page in SharePoint Online, Click on the New-> Page, to create a new page.
- Select a blank page in SharePoint Online. Click on the Create.
- Give a name to the SharePoint page such as Finance Report. If you are using the existing page to embed the report link, then click on the Edit icon on SharePoint Online Page.
- Select the Add icon present below section on the SharePoint page.
- Then search for Power bi web part in SharePoint Online and select it.
- Click on Add Report in SharePoint Online
- Then paste the embed link, under the power bi report link in SharePoint Online.
- Under the page name, you can select the page.
- Under the Display section, you can choose the Display size of the report in SharePoint.
- Click on the publish. in SharePoint Online
- Now you can see the Power bi report in SharePoint Online.
Here we will see how to integrate the report in SharePoint Online by using the Power Bi report URL.
Also, we will use the same report i.e. financial report, we have used above( embed power bi report to SharePoint online using embed link)
- Go to the same report in Power Bi i.e. Financial report.
- Copy the URL from the address bar.
- You can follow the above topic (embed power bi report to SharePoint online using embed link) to create the page in SharePoint Online or you can use the same financial page which we have created before i.e. Finance Report page in SharePoint.
- On the Finance report page in SharePoint, click on the add icon present below every section and then select the power bi web part
- Then click on the Add report.
- Then under the power bi report link, paste the URL of the power bi report.
- Then click on the publish.
- Now you can see the power bi report in SharePoint Online.
This is how we can embed a report using Power BI web part in SharePoint Online.
To display a report by using SharePoint Online embed web part, we need to first get the embed code.
If you got an error like “Contact your admin to enable embed code creation” while getting the embed code, follow the below section.
Let us see, how to embed power bi report to SharePoint Online using embed web part. Here we will use the above report i.e Financial report.
- Open The Financial report in power bi service.
- Then select the File, from the Dropdown select the Embed Report-> Publish to the web(publicly).
- On the Embed code page in Power bi service, Under Link you can send to an email, then you can copy the embed link and you can send it by email.
- Under HTML you can paste into a website, copy that embed code
- Next, you can set the size of the report
- Then under placeholder image, you can set the image, and then you can set the default page.
- On the right side of the Embed code page, you can see the preview of your report.
- Once you copy the embed code, you can close the Embed code page
- Now Go to SharePoint Online where you want to embed the power bi report.
- Open the page in SharePoint Online
- Click on the Add icon which is present below the section of the SharePoint Page.
- Select Embed web parts to add embed code for Power bi report.
- Now you can paste the embed code under the Website address or Embed code in SharePoint Online.
- Click on Republish.
Now you can see the Power Bi report in SharePoint Online.
This is how we can embed a Power BI report by using a SharePoint Online embed web part.
How to enable publish to web option in Power bi
To get the embed code, publish to web option should be enabled in the Office 365, else you will get an error, contact your admin to enable embed code creation.
To fix, this error, let us first understand what is Publish to web in Power BI?
Publish to web is the feature in Power Bi is a free way of sharing Power Bi report with the public.
If the report is published by using publish to web feature, is not secure, and the feature is available to anyone, who has access to the link or embeds code generated through this method.
This feature is controlled by the Power Bi administrator of your tenant and can publish to web or not.
Contact your admin to enable embed code creation
Here we will see how to solve the error message “Contact your admin to enable embed code creation” in the Power Bi service.
So when you select publish to web feature in Power Bi, you will come through this error, if permission to share publicly embed code or embed link is not given to you.
To solve this error, you must have the power bi administrator role or else ask the power bi administrator of your tenant to give permission.
If you have login as admin in Power bi, then
- Click on the More option in power bi.
- Then go to Setting-> Admin portal in Power Bi.
- Navigate to tenant setting, under Export and sharing setting.
- In the publish to web section, enable the publish the web feature.
- Under how embed code works, choose to Allow existing and new codes.
- Under Apply to, choose the entire organization
- Click on Apply.
This is how we can fix, error, contact your admin to enable embed code creation, and how to enable publish to web option in Power bi?
Now, let us see, how to embed power bi report in classic sharepoint page.
We can easily embed a power bi report in SharePoint Online site by using a script editor web part.
Open any SharePoint web part page, then add a script editor web part. Then paste the Power BU embed code there. You can see below the Power BI report is appearing on a classic SharePoint site.
On SharePoint classic page, we even can use a SharePoint content editor web part to display a Power BI report.
You may like the following Power BI articles:
- How to combine multiple files from SharePoint folder in Power BI
- Display COVID-19 Power bi report in PowerApps
- How to embed Power bi report in PowerApps portal
- Power BI: How to Connect Most Recent File from a Folder
- Power bi best practices
- Power Bi Filter Functions with Examples
- Power Bi Table Manipulation Functions
In this tutorial, we learned different ways to embed a Power BI report to SharePoint Online, like by using the Power BI web part, and SharePoint Online embed code web part. How to embed a Power BI report in a classic SharePoint page using the script editor web part. This is how to publish power bi report to sharepoint.
We also discuss how to fix the error, contact your admin to enable embed code creation and how to enable publish to web option in Power bi?
I am Bijay from Odisha, India. Currently working in my own venture TSInfo Technologies in Bangalore, India. I am Microsoft Office Servers and Services (SharePoint) MVP (5 times). I works in SharePoint 2016/2013/2010, SharePoint Online Office 365 etc. Check out My MVP Profile.. I also run popular SharePoint web site SPGuides.com