This summary is produced by the author, and not by AI.
This article mentions the Tabular Editor 2 CLI. For new work, prefer the Tabular Editor 3 CLI, the current command-line interface for automating semantic model tasks.
VS Code (or Visual Studio Code) is a free, open-source, lightweight code editor and development environment from Microsoft. Usually, VS Code is a tool that developers and IT professionals use. However, Power BI professionals can also make great use of it, as well, even if you aren’t from a technical or computer sciences background.
In this article, we explain why VS Code is useful for Power BI developers and highlight some common and practical scenarios. If you’ve never used VS Code before, we encourage you to download and try it… especially if one of the following scenarios could be helpful for you.
Normally, when you save Power BI files as a Power BI Desktop (.pbix) format, you can’t view or alter their contents. For instance, if you want to find and replace fields in a report, extract a theme, or change a property (either manually or programmatically), it isn’t supported by Microsoft. Also, if you want to get the most from AI tools other than Copilot in Power BI, then you must use a different format than .pbix to save your files.
To do more with Power BI files, you should use the Power BI Project (PBIP) format. PBIP is an alternative to the Power BI Desktop (.pbix) format for Power BI semantic models and reports. When you save a .pbix as a PBIP, it saves multiple files in a folder (your “project”), which you can open and browse in any text editor. However, most text editors only let you open a single file at a time. In VS Code, you can open a folder, allowing you to view and navigate its contents.
You can enable the PBIP format from the preview settings in Power BI Desktop. There, you’ll also see settings for other formats for semantic models (the Tabular Model Definition Language, or TMDL) and reports (the Power BI enhanced report format, or PBIR). These formats make the metadata for semantic models and reports easier to read and to work with. For PBIR, this is especially important, because modifying the legacy report format is unsupported by Microsoft.Additionally, while these are preview features, they are mature and well-adopted in the community. We do advise using the PBIP format instead of .pbix files, if you think it will bring you value. If not, it’s totally fine to keep using pbix; it depends on where you’re at in your Power BI journey.
There are multiple reasons why this might be useful:
In VS Code, you can install free extensions which can provide added, custom functionality. Extensions are a very useful tool to make certain operations more convenient or efficient from within VS Code. There are several extensions that help you work with PBIP files:
hex, rgb, css, etc.) which is useful when inspecting any metadata or expressions that work with color. Note that colors are shown by default in VS Code as boxes, but colorize provides it as a more visible background.One downside of the PBIP format is that the additional files and file types (like JSON) introduce a lot of complexity that can overwhelm some Power BI creators. For instance, once you have a model or report in PBIP format, you need to handle the entire project when you want to move, copy, share, or even rename it. In short, using the PBIP format means that you also must change the way you manage the files. Managing that change is important, and it is something that you must consider to enable your users and peers (or to adapt yourself).
VS Code can help with this, but it is also worthwhile to consider setting up source control in a remote Git repository.
A key advantage of the PBIP format is that you can more easily track changes to your Power BI semantic models and reports. Unlike a .pbix file, in a Power BI Project, you can see all of the changes, including changes to code (like DAX and Power Query), properties (like display folders or format strings) and report visuals or configuration (like formatting or fields used). To do this, you should set up source control with a remote Git repository, such as a GitHub repo or Azure DevOps repo. For more information, see this and related content in the Microsoft documentation.
Once you download and set up Git and a remote repository, you can use VS Code for source control management. This means that you can view your changes in VS Code, and commit then push those changes to the remote repository. VS Code will also show a graph view, which visualizes the recent history of changes for a file or project.
In the example, you can see the files on the left that have changed. File changes have “M” (for “Modified”). On the right, you can see a changed file, which is a text box in a Power BI report. The value of the text has changed from “Sales report (title)” (red; the old state) to “Sales report” (green; the current state). This is a trivial or frivolous example of a change, but a simple one just to illustrate what it looks like.
Some extensions that might help include:
Note that using VS Code isn't necessary for source control or Git integration. However, it provides a simple and easy-to-use interface to let you manage changes to local files. For most people, it will be a better alternative than using git commands in the command-line, or other source control management tools. It is also commonly used by many Power BI professionals, so you're likely to see it in demos and be able to learn more from others in the community.
In the previous two sections, we mentioned Fabric Studio, a free, third-party VS Code extension from Gerhard Brückl. It uses the Fabric APIs to provide a visual overview of your workspace contents from within VS Code, as well as a rich set of functionality to make it easier to work with various Fabric items and operations. In short, this means that you can use Fabric Studio to manage a workspace from your desktop in VS Code. This can be quicker and more convenient than doing so in the browser, particularly since Fabric Studio provides you full access to item definitions.
Fabric Studio is an extension that will be particularly useful for those who manage multiple workspaces or administrate an entire Fabric tenant. Since these APIs work with Power BI Pro, Premium-Per-User, and Premium capacities as well, this means that you can use Fabric studio even if you don’t use Fabric. Note however that since the extension uses the Fabric APIs (including the admin apis), you must have access to use those APIs in order to use this extension. If your tenant administrator has more restrictive tenant settings and you don’t have access to the APIs, then you won’t be able to use Fabric Studio.
The following image shows you an example of what Fabric Studio looks like in VS Code:
The example shows the Fabric workspaces with a hierarchical structure. In Claude’s Workspace, we’ve expanded the Fitness Model and its definition to see various objects like tables. Right-clicking the model shows various actions like downloading it as a PBIP or renaming the item. Below that are deployment pipelines and other sections, and to the right is the TMDL file for the Sets table, syntax-highlighted because of the TMDL extension.
Note that Fabric Studio doesn’t just let you manage parts of workspaces and items. You also can view information such as:
In addition to seeing this information, you also have a wide range of operations, including:
If you’re a Fabric administrator or you manage many different workspaces, Fabric Studio is a must-have extension that will probably make your life easier and save you time.
One of the most effective ways to use AI with Power BI semantic models and reports is by using a coding agent that integrates with VS Code. A coding agent is an AI tool that can't only chat, but can interact with files on your local machine, or execute code on your behalf to complete tasks. It's a much more powerful way to use an LLM than copy and pasting content to and from a conversation. Coding agents are designed to facilitate working with code, including metadata files like those in a PBIP. Examples include GitHub Copilot and Claude Code.
These coding agents produce better results when you provide them special configuration and instruction files in a project. In VS Code you can manage these files, but also your PBIP files. Thus, you can best orchestrate a coding agent and have visibility on the changes they are making. Together with source control (which helps you track and reverse changes by a coding agent) and Fabric Studio (which lets you validate deployments), this makes VS Code a logical hub from which you are using AI to help facilitate Power BI development.
The following is an example of what it looks like when you use Claude Code within VS Code to make changes to Power BI reports:
The video shows Claude Code running in the terminal, making changes to the report metadata. This is hard to depict in a static screenshot, so here’s a video showing Claude Code making a Power BI report from a wireframe. The purpose of the demo is just to show how a coding agent makes changes to a report:
The video shows an example of Claude Code interpreting a wireframe and realizing a first version of the Power BI report. It does not show "AI making reports" or imply that AI can or will replace report creators; that is nonsense. Rather, these AI tools are used as a method to save report creators time and provide an alternative to using the click-tax-heavy Power BI formatting panes. Making this report page might take longer with the UI than with Claude Code, for instance. The demonstration here shows Claude Code creating the report without invoking special tools, skills, or MCP servers; with those, it is even faster, and more convenient.
If you are interested in experimenting with AI tools to help you with Power BI, then VS Code is definitely something that will help. Note, however, that you can still use many of these tools from a simple terminal without VS Code, but then it is harder to orchestrate the agent and manage its changes to files.
If you want to do more with Power BI semantic models and reports, then you should definitely consider using the PBIP format with VS Code. VS Code is a valuable first-party tool that brings many benefits to Power BI developers across a wide range of scenarios. We’ve covered just a few of these here, from source control and custom extensions to use of agentic coding tools. However, this is just scratching the surface. If you have some tips for how to use VS Code in your Power BI projects, let us know in the comments below or tag us (Tabular Editor) on social media.
Take your semantic models further with Tabular Editor.
Give Tabular Editor a spin