How to Import Data from MySQL to Power BI
Transforming raw MySQL data into insightful dashboards doesn't have to be a complicated process. By connecting your MySQL database to Power BI, you can unlock powerful reporting capabilities and make your data much more accessible to your entire team. This guide will walk you through exactly how to set up the connection and start visualizing your data.
Why Connect MySQL to Power BI?
Before jumping into the steps, it's helpful to understand what you gain by making this connection. While MySQL is fantastic for storing and managing structured data, it’s not designed for intuitive data exploration and reporting. That's where a business intelligence tool like Power BI comes in.
- Powerful, Interactive Visuals: Power BI turns rows and columns from your database into interactive charts, graphs, and maps that are easy to understand. Users can click, filter, and drill down into the data without needing any technical skills.
- No SQL Required for Analysis: Once the connection is set up, your team can explore the data without writing a single line of SQL. This empowers marketers, salespeople, and executives to find their own answers, freeing up your technical teams.
- Combine Data from Multiple Sources: Your MySQL database holds important information, but it's likely not the full picture. Power BI lets you combine your MySQL data with other sources like Google Analytics, CSV files, Salesforce, or Excel spreadsheets to create a single, unified view of business performance.
- Automated Data Refreshes: You can schedule your Power BI reports to automatically update, ensuring that everyone is looking at the most current data without any manual work. No more exporting CSVs every Monday morning.
Prerequisites: What You’ll Need Before You Start
To ensure a smooth connection process, make sure you have the following ready to go. Tackling these first will save you from hitting a snag midway through.
1. Power BI Desktop: You'll need the free Power BI Desktop application installed on your Windows computer. If you don't have it yet, you can download it directly from Microsoft.
2. MySQL Database Credentials: You’ll need the connection details for your database. If you don't have these, you may need to ask your database administrator or developer.
- Server Name or IP Address: This is the address of your database (e.g.,
database.yourcompany.comor192.168.1.100). - Database Name: The specific database you want to connect to.
- Username and Password: The credentials needed to access the database.
3. MySQL Connector/NET Installed: This is the most common reason connections fail. Power BI uses a special driver to communicate with MySQL databases. You must have this driver, called MySQL Connector/NET, installed on the same machine where you’re running Power BI Desktop. The version of the connector should match your Power BI installation (64-bit is most common).
- You can download it for free directly from the official MySQL website. Close Power BI Desktop, install the connector, and then reopen Power BI.
Free PDF · the crash course
AI Agents for Marketing Crash Course
Learn how to deploy AI marketing agents across your go-to-market — the best tools, prompts, and workflows to turn your data into autonomous execution without writing code.
Step-by-Step: How to Connect MySQL to Power BI
Once you’ve got your prerequisites sorted, the actual connection process is quite straightforward. Follow these steps to get your data flowing.
Step 1: Open Power BI and Select "Get Data"
Launch Power BI Desktop. In the "Home" tab on the ribbon at the top of the window, click on the Get Data icon. A dropdown will appear, click More... at the bottom to open the full list of available data sources.
Step 2: Find the MySQL Database Connector
In the "Get Data" window, you’ll see a list of categories on the left. You can either select the "Database" category to find it or, more easily, type "MySQL" into the search bar at the top left. Select MySQL database and click the Connect button.
Step 3: Enter Your Server and Database Details
A new window will pop up asking for your connection details. This is where you'll use the credentials you gathered earlier.
- Server: Enter the server name or IP address of your MySQL database.
- Database: Enter the name of the database you want to pull data from.
You’ll also see an "Advanced options" dropdown. You can usually leave this empty, but it's where you could write a custom SQL query to import specific data instead of a whole table.
A quick note on Data Connectivity mode: Import vs. DirectQuery
In this same dialog, under "Data Connectivity mode," you have two main choices:
- Import (Recommended): This is the default and most common option. Power BI takes a copy of your data from MySQL and stores it within your Power BI file (.pbix). Dashboards are very fast because Power BI is querying its own internal, highly compressed data store. You’ll need to set up scheduled refreshes to keep the data current.
- DirectQuery: This option creates a live connection to your MySQL database. No data is stored in the Power BI file. Every time you interact with a visualization, Power BI sends a query directly to your database. This is great for real-time reporting on extremely large datasets but can be slower and place a heavier load on your database server.
For most use cases, especially when starting out, Import is the best choice.
Step 4: Enter Your Credentials
After clicking "OK," Power BI will prompt you for your login credentials. On the left side, select the Database tab (not Windows). Enter the User name and Password for your MySQL database. You can leave the "Encrypt connection" setting at its default unless you have specific security requirements.
Click Connect.
Step 5: Select Your Tables in the Navigator
If your credentials are correct, a window called "Navigator" will appear. This window shows you all the tables and views available inside the database you connected to. It’s like a filing cabinet for your data.
Browse through the list and click the checkbox next to each table you want to import into your report. When you select a table, a small preview of its data will appear on the right side of the window, helping you confirm you've chosen the right one.
Free PDF · the crash course
AI Agents for Marketing Crash Course
Learn how to deploy AI marketing agents across your go-to-market — the best tools, prompts, and workflows to turn your data into autonomous execution without writing code.
Step 6: Load or Transform Your Data
At the bottom right of the Navigator window, you'll see two options: Load and Transform Data.
- Load: This option will immediately load the selected tables directly into your Power BI data model, just as they are. This is the quickest way to get your data in.
- Transform Data: This is a best practice. Clicking this opens the Power Query Editor, a powerful tool for cleaning and shaping your data before it gets loaded into your report.
It's almost always a good idea to click Transform Data first. Even if your data looks clean, the Power Query Editor allows you to:
- Remove unnecessary columns: The fewer columns you load, the faster your report will be.
- Rename columns: Change database names like
cust_first_nameto something more readable likeCustomer First Name. - Check data types: Make sure numerical columns are formatted as numbers and dates are formatted as dates. Power BI is pretty good at guessing, but it's worth a check.
- Filter rows: If you only need data from the last two years, you can apply a filter here to reduce the model size.
Once you are happy with your data's shape in the Power Query Editor, click the Close & Apply button in the top-left corner. Power BI will then import your prepared data, and you’ll be ready to start building visualizations in the report designer.
Final Thoughts
Connecting MySQL to Power BI is a common and impactful way to make sense of your database information. By following these steps, you can create a link that lets you build dynamic reports, blend data sources, and provide actionable insights for your team without them ever needing to touch the database directly.
While Power BI is a fantastic tool, we know firsthand that the setup, data transformation, and modeling process can still be time-consuming, especially for teams juggling multiple platforms and tight deadlines. We built Graphed to remove that friction entirely. You can connect sources like MySQL in seconds, and instead of clicking through endless setup windows and GUIs, you just describe the dashboard you want in simple English. Ask, "Show me a dashboard of user signups from MySQL compared to ad spend from Google Ads last quarter," and get an interactive, real-time dashboard faster than you can open another browser tab.
Related Articles
Facebook Ads for Insurance Agents: The Complete 2026 Strategy Guide
Learn how to use Facebook ads to generate quality leads for your insurance agency in 2026. This comprehensive guide covers targeting, creative strategies, and compliance rules.
Facebook Ads for Real Estate Agents: The Complete 2026 Strategy Guide
Master Facebook ads for real estate agents in 2026. Learn targeting, ad formats, budgets, and creative best practices to generate more leads.
Facebook Ads for Movers: The Complete 2026 Strategy Guide
Learn how to run Facebook ads for movers that actually generate booked jobs—not just clicks. Budget, targeting, funnel strategy, and creative that converts.