DEV Community

melody mulei
melody mulei

Posted on

How to Publish and Embed Power BI Reports on the Web Using IFrames – A Complete Step-by-Step Guide

Introduction
In today’s data-driven world, insights are only valuable when they are accessible. Creating a dashboard is just the beginning, the real impact comes from sharing it effectively.
In this guide, I’ll walk you through the complete process of publishing a Power BI report to the cloud and embedding it into a website using iframes — so anyone can interact with your insights directly from a browser.
I’ll use my Electronics Sales Assignment (built with queries, DAX, star schema modeling, currency conversion, KPIs, charts, and multi-page navigation) as a practical example.

What is Power BI?
Power BI is a powerful business intelligence tool developed by Microsoft that allows users to:
• Transform raw data into meaningful insights
• Build interactive dashboards and reports
• Share data visually with stakeholders
From data cleaning using Power Query to advanced calculations with DAX, Power BI provides an end-to-end analytics solution.

Why Publish and Embed Power BI Reports?
Publishing moves your report from your local machine to Microsoft’s cloud (Power BI Service), enabling:
• Scheduled data refreshes
• Easy sharing and collaboration
• Secure or public embedding on websites, blogs, intranets, or dashboards
Embedding with iframes enables you to bring fully interactive reports into any web page, without requiring a Power BI license for viewers in public mode.

Overview of the Publishing Process
Publishing a Power BI report involves four key steps:

  1. Creating a workspace
  2. Uploading and publishing your report
  3. Generating an embed code
  4. Embedding the report on a website Let’s go step by step.

Step 1: Create a Workspace in Power BI Service
A workspace is a collaborative environment where reports, dashboards, and datasets are stored and managed.
Steps:

  1. Go to Power BI Service (https://app.powerbi.com)
  2. Sign in with your account
  3. On the left sidebar, click Workspaces
  4. Click + New Workspace
  5. Fill in: o Workspace Name (e.g., John Doe) o Description (optional)
  6. Click Save

Step 2: Upload and Publish Your Report
Now that your workspace is ready, it’s time to upload your .pbix file.
Steps:

  1. Open Power BI Desktop
  2. Load your Electronics Sales report
  3. Click Publish (top ribbon)
  4. Select your created workspace
  5. Wait for the confirmation message Alternatively (via Power BI Service):
  6. Open your workspace
  7. Click Upload → Browse files
  8. Upload your .pbix file

Step 3: Generate the Embed Code
Once your report is published, you can generate a link or embed code.
Steps:

  1. Open your report in Power BI Service
  2. Click File → Embed report → Publish to web (public)
  3. Click Create embed code
  4. Copy: o The iframe embed code, or o The direct link

Step 4: Embed the Report into a Website
Now, let’s bring your dashboard to life on a website.

Steps:

  1. Open your website’s HTML file
  2. Paste the iframe code
  3. Replace with your embed link
  4. Save and refresh your website

Now your fully interactive report (with slicers, filters, drill-downs, and page navigation) is live on the web!

Key Insights

  1. Power BI is not just about building dashboards—it’s about sharing insights effectively
  2. Workspaces help manage and organize reports
  3. Embedding dashboards makes insights accessible beyond Power BI users
  4. Always consider data privacy before using public embed options
  5. Combining Power BI with platforms like GitHub and blogs strengthens your data portfolio

Final Thoughts
Publishing and embedding Power BI reports transforms your work from static analysis into interactive, shareable insights. Whether you're presenting to management or showcasing your skills, this is a critical step in your data journey.

With this Electronics Sales project, you’ve not only analyzed data, you’ve learned how to deliver it professionally.

Top comments (0)