Reducing Power BI File Size

Reducing Power BI File Size – A Complete Guide

Power BI files (.pbix) can become large due to excessive data, high-cardinality columns, unnecessary visuals, complex DAX calculations, or inefficient modeling. A large file size can slow down report performance, increase refresh time, and make sharing difficult.

This guide provides a detailed, step-by-step walkthrough of the best techniques to reduce Power BI file size and optimize performance.


🔹 Why Reduce Power BI File Size?

Improves report performance – Faster loading time
Optimizes memory usage – Efficient processing
Enhances dataset refresh speed – Reduces refresh failures
Easier sharing and publishing – Faster cloud uploads
Reduces Power BI Premium costs – Efficient resource utilization


Section 1: Checking File Size and Storage Usage

Before optimizing, you need to analyze why the file is large.

🔹 Step 1: Check Power BI File Size

1️⃣ Open the Power BI .pbix file
2️⃣ Click on File → Save As
3️⃣ The file size is displayed before saving

🔹 Step 2: Check Data Model Storage

1️⃣ Click on File → Options and Settings → Options
2️⃣ Under Current File, select Data Load
3️⃣ Look at Storage Mode (Import / DirectQuery / Hybrid)
4️⃣ Use DirectQuery for external data sources to reduce file size

🔹 Step 3: Analyze Dataset Size in VertiPaq Analyzer

VertiPaq Analyzer (available in DAX Studio) helps identify large tables and columns consuming memory.

1️⃣ Download DAX Studio (https://daxstudio.org/)
2️⃣ Open your Power BI file
3️⃣ Click on External Tools → DAX Studio
4️⃣ Select View Metrics → Advanced Tab
5️⃣ Look at Table Size, Column Size, and Data Cardinality
6️⃣ Identify which tables/columns are consuming most of the space

Result: Now you know which elements need optimization.


Section 2: Removing Unnecessary Data

One of the biggest reasons for large Power BI files is storing unused tables, columns, or rows.

🔹 Step 1: Remove Unused Tables

1️⃣ Open Power BI Desktop
2️⃣ Click Model View
3️⃣ Identify tables not used in any visuals or relationships
4️⃣ Delete them from Power Query (Transform Data → Remove Table)

🔹 Step 2: Remove Unused Columns

1️⃣ Open Power Query Editor (Transform Data)
2️⃣ Identify columns that are not used in calculations or visuals
3️⃣ Select the columns → Click Remove Columns

🔹 Step 3: Remove Unnecessary Rows

If your dataset contains historical data or unwanted records, filter them out.

1️⃣ Go to Power Query
2️⃣ Click Home → Keep Rows → Keep Top Rows (if only recent data is needed)
3️⃣ Use Date Filters to exclude old records

Result: Smaller dataset with only required data.


Section 3: Reducing Column Cardinality

Columns with high cardinality (unique values) take up more memory in Power BI’s VertiPaq engine.

🔹 Step 1: Convert High-Cardinality Columns

1️⃣ Identify columns with many unique values (e.g., Transaction ID, DateTime)
2️⃣ Replace detailed IDs with categorical values

  • Instead of “OrderID” (numeric ID per row), use “OrderCategory”
  • Instead of “Exact DateTime”, round to “Date” or “Hour”

🔹 Step 2: Optimize Text Columns

1️⃣ Convert long text fields into numeric category codes
2️⃣ Avoid storing unnecessary long descriptions

Example:
“2025-03-05 14:23:45” → ✅ “2025-03-05”
“Customer Name: John Doe” → ✅ “Customer ID: 123”

Result: Less storage needed for high-cardinality columns.


Section 4: Changing Data Storage Mode

Power BI supports different storage modes that impact file size:

  • Import Mode – Stores all data inside Power BI (Larger file size)
  • DirectQuery Mode – Connects live to the source (Smaller file size)
  • Hybrid Mode – Mix of both

🔹 Step 1: Switch to DirectQuery

If your dataset is large, switch from Import Mode to DirectQuery.

1️⃣ Click Model View
2️⃣ Select a table
3️⃣ In Properties, change Storage Mode to DirectQuery
4️⃣ Apply changes

Result: Data is no longer stored inside Power BI, reducing file size.


Section 5: Optimizing DAX Measures

Complex DAX calculations can increase memory usage.

🔹 Step 1: Replace Calculated Columns with Measures

  • Calculated Columns are stored in the model → Increases file size
  • Measures are calculated dynamically → Doesn’t increase file size

Example:

Calculated Column (BAD)

SalesTotal = Orders[Quantity] * Orders[UnitPrice]

Measure (GOOD)

SalesTotal = SUMX(Orders, Orders[Quantity] * Orders[UnitPrice])

🔹 Step 2: Avoid Unused Measures

1️⃣ Click Model View
2️⃣ Identify measures not used in visuals
3️⃣ Delete unused measures

Result: File is optimized without extra calculations.


Section 6: Removing Unused Visuals and Pages

Unused visuals consume memory even if not displayed.

🔹 Step 1: Remove Extra Pages

1️⃣ Open Power BI Desktop
2️⃣ Click Pages (bottom panel)
3️⃣ Right-click unused pages → Click Delete

🔹 Step 2: Remove Complex Visuals

1️⃣ Avoid using too many slicers, filters, and custom visuals
2️⃣ Use default visuals instead of heavy third-party visuals
3️⃣ Reduce the number of data points in charts

Result: Improved report performance and smaller file size.


Section 7: Compressing Power BI File

After cleaning up your data, compress the file further.

🔹 Step 1: Turn Off Auto Date/Time

1️⃣ Click File → Options → Data Load
2️⃣ Disable Auto Date/Time

🔹 Step 2: Enable Data Reduction in Power Query

1️⃣ Open Power Query Editor
2️⃣ Click Transform → Reduce Rows
3️⃣ Use Remove Duplicates

Result: More optimized Power BI file.


Conclusion

Reducing Power BI file size improves performance and makes reports easier to manage.

Quick Summary of Optimization Steps

Remove unnecessary tables, columns, and rows
Reduce column cardinality (convert high-cardinality columns)
Switch to DirectQuery instead of Import Mode
Optimize DAX calculations (use Measures instead of Calculated Columns)
Remove unused visuals, pages, and filters
Enable compression settings

🔹 Final Tip: Regularly review your Power BI file and remove unused elements to keep it lightweight and efficient.

Leave a Reply

Your email address will not be published. Required fields are marked *