--- id: pbixray version: "0.15.4" license: MIT license_treatment: permissive maintenance: active --- # pbixray — A Python library to parse and analyze PBIX files used with Microsoft Power BI and Excel PowerPivot. License: permissive · Maintenance: active · Downloads: 260.1K/mo ## What it is and what it does PBIXRay is a Python library for reading and analyzing Microsoft Power BI PBIX files, Excel PowerPivot models, and Analysis Services backup files. It extracts the internal data model—tables, columns, relationships, DAX expressions, Power Query code, security rules, and metadata—and exposes them as pandas DataFrames or raw Python objects. The library handles both small models held in memory and large models that exceed available RAM by streaming to disk and memory-mapping the result. Typical use cases include auditing Power BI models for DAX logic and data lineage, programmatically inspecting security configurations (row-level and object-level security), extracting Power Query transformations for documentation or migration, and bulk-analyzing many PBIX files. The library is the Python implementation of logic from the DuckDB PBIX extension, so it integrates naturally with data analysis workflows that already use pandas and numpy. Use it for: - Audit Power BI models for DAX measures, calculated columns, and aggregation rules without opening Power BI Desktop. - Extract Power Query M code and parameters from PBIX files for documentation or migration to other tools. - Inspect row-level and object-level security configurations across many Power BI models programmatically. - Retrieve table data and schema from PBIX files as pandas DataFrames for analysis or export. - Stream large Power BI tables in chunks to avoid loading entire models into memory. - Analyze relationships, perspectives, and metadata across a portfolio of Power BI or PowerPivot files. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Parse and extract metadata, tables, DAX expressions, Power Query code, and security configurations from Microsoft Power BI PBIX files, Excel PowerPivot models, and Analysis Services backup files. Yes. The package is actively maintained, has low install friction, carries no known vulnerabilities, and solves a real gap: programmatic inspection of Power BI models without requiring Power BI Desktop. MIT licensing removes legal friction. Install if you need to audit, extract, or analyze PBIX files at scale or in automation; skip if you only work with Power BI interactively. ## Install pip install pbixray uv add pbixray poetry add pbixray ## Installing pbixray Before you install: Low friction install with a pure-Python wheel. Actively maintained with a recent release; 140 repository stars indicate modest but steady adoption. Seven runtime dependencies are all established libraries (numpy, pandas, apsw for SQLite, plus xpress and xmhuffman for compression). License in practice: MIT license is permissive; you can use, modify, and distribute this package with minimal restrictions, provided you retain the license notice. Quickstart: pip install pbixray from pbixray import PBIXRay model = PBIXRay('path/to/your/file.pbix') tables = model.tables df = model.get_table('TableName') Requires Python 3.8 or later. For large models, pass on_disk=True to stream to disk instead of loading the entire decompressed model into memory. Verify before relying: - Performance characteristics and memory overhead for typical model sizes are not quantified in the fact sheet. - Compatibility with specific Power BI versions or model complexity limits is not documented in the excerpt. ## Package facts - License: MIT (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 260.1K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags power bi pbix parser, extract power bi metadata, power query analysis, dax expression extraction, pbix file reader, power bi model inspection, powerbi data model parser, power-bi, data-model-inspection, pbix-parser [View on SkillFed](https://skillfed.io/packages/pbixray) · [View on PyPI](https://pypi.org/project/pbixray/)