How to Connect Jira to Power BI Using API
You have mission-critical project data sitting in Jira and you want to visualize it in Power BI to spot trends, track progress, and build detailed reports for stakeholders. A quick search reveals marketplace apps that promise to bridge the gap, but what if you want full control over your data without another monthly subscription fee? By connecting directly to Jira’s REST API, you can pull exactly the data you need and build completely custom dashboards. This article will show you, step-by-step, how to connect Jira to Power BI using the API, transform the data, and build the foundation for a powerful reporting setup.
Why Connect Directly with the Jira API?
While third-party connectors can be convenient, they often come with limitations and costs. Learning to use the API directly offers some significant advantages that are worth the initial effort:
It’s Free: Using the Jira REST API doesn't add another subscription to your budget. You’re using built-in functionality that you already have access to.
Total Flexibility: Connectors often provide a predefined set of fields. With the API, you can pull any field available in your Jira instance, including every custom field you’ve created. You’re in complete control of the data you bring into Power BI.
Deeper, More Complex Queries: You can use Jira Query Language (JQL) to craft highly specific, complex queries. Need to see all high-priority bugs in a specific project assigned to a certain team that were updated in the last 14 days? An API call with the right JQL is the most direct way to get that exact dataset.
Control Over Data Refreshes: You are not reliant on a third-party service's refresh schedule. You can configure data refreshes directly within the Power BI Service to meet your team’s specific needs, whether that’s daily, hourly, or somewhere in between.
Phase 1: Your Jira Prep Work
Before you even open Power BI, you need three key pieces of information from your Jira account. Getting these sorted out first will make the process much smoother.
Step 1: Generate Your Jira API Token
For security, Jira doesn't let you use your plain password for API access. Instead, you'll generate a special API token. Think of it as a unique, secure password specifically for applications like Power BI.
Log into your Atlassian account page at id.atlassian.com.
Navigate to Security from the left-hand menu.
Find the API token section and click Create and manage API tokens.
Click the Create API token button.
Give your token a recognizable label, like "PowerBI_Connection," so you know its purpose later.
Click Create. A new token will be generated.
This is important: Click Copy and save this token somewhere safe and secure, like a password manager. Jira will not show you this token again once you close the window.
Step 2: Identify Your Jira Cloud Site URL
This is simply the main URL you use to access Jira. It typically follows this format: your-company-name.atlassian.net. Make a note of this URL, you'll need it shortly.
Step 3: Craft and Test Your JQL Query
Jira Query Language (JQL) is how you tell Jira exactly which issues you want to retrieve. Before using it in an API call, it’s best to build and test your query directly within Jira's issue navigator.
In Jira, go to Filters > Advanced issue search. This will give you a JQL input box where you can experiment.
Here are a few examples to get you started:
Simple (all issues from one project):
More Specific (unresolved bugs in a specific sprint):
Time-Based (stories created in the last 30 days):
Play around until the query returns exactly the set of issues you want to analyze in Power BI. Once you're satisfied, copy your final JQL string and save it.
Phase 2: Connecting Jira Data in Power BI
With your site URL, API token, and JQL query ready, it's time to open Power BI Desktop and start pulling in the data.
Step 1: Open the Power Query Editor
In Power BI Desktop, go to the Home tab and click on Transform data. This will open the Power Query Editor, where all the connection and transformation magic happens.
Step 2: Start a New "Web" Query
Inside the Power Query Editor, click New Source > Web. A dialog box will appear. Here, you’ll want to select the Advanced option, as this is what allows us to add the necessary authentication headers.
Step 3: Construct the API Request
This is where you combine the pieces you prepared earlier. The Jira API lets you search for issues using a specific URL structure.
In the "URL parts" box, enter your base Jira API endpoint. It will look like this, but with your own site URL:
Now, let's configure the authentication header needed to authorize your request:
Underneath "HTTP request header parameters," add a new header.
In the first box, type:
AuthorizationFor the value, you have to format your credentials properly. We'll use "Basic" authentication. The format is:
Basic <base64_encoded_email:token>.
Don’t worry, you don’t need to encode this by hand. Simply create a text string of your login email and your API token, separated by a colon, like this:
Then use an online Base64 encoder tool to convert that string. Once encoded, your string will look something like this:
Paste the final value into the second header box, making sure to include the word "Basic" followed by a space at the front:
Step 4: Making A POST Request
The GET method works, but for complex JQL queries, it's often more reliable to use a POST request. This way, you send the JQL in the body of the request instead of trying to cram it (and encode it) into the URL.
To do this, you’ll need to edit the source code slightly in the Advanced Editor.
After creating the initial connection, go to the Home tab in Power Query and click Advanced Editor.
Modify the
Web.Contentsfunction to include aContentfield. This is where you'll pass your JQL as a JSON object.
Your M code should look like this. Replace the placeholders with your actual site URL, JQL, and encoded credentials:
Click Done. If everything is configured correctly, Power Query will connect to Jira and return a record object.
Phase 3: Shaping Your Jira Data in Power Query
The raw response from Jira is in JSON format, which isn't very user-friendly. Your next job is to transform this nested data into a clean, flat table that Power BI can use.
Step 1: Drill Down into the "Issues" List
The raw data from Jira is a record. The actual list of Jira issues is typically inside a field named issues. Click on the word "List" next to issues to drill down into it.
Step 2: Convert to a Table and Expand Columns
You now have a list of records. To work with this, you need to turn it into a table.
Go to the Transform tab at the top and click To Table.
Accept the default settings and click OK.
You'll now have a single column named "Column1" filled with records. Click the expand button (the icon with two diverging arrows) at the top of the column header.
A list of all available fields will appear. For your first expansion, we recommend deselecting all and then only checking
keyandfields.Keyis your Jira ticket ID (e.g., PROJ-123), andfieldscontains most of the valuable data like the summary, status, assignee, reporter, etc. Click OK.
Step 3: Expand the Nested "Fields" Data
You now have two columns: key and a fields column that still contains records. Repeat the expansion process for the fields column.
Click the expand button on the
fieldscolumn header.This time, you'll see a long list of fields:
summary,status,assignee,reporter,issuetype,created,updated, and all your custom fields (which often appear with names likecustomfield_10019).Select only the fields you actually need for your report. Pulling in everything will clutter your dataset. For example, select
summary,status,issuetype, andassignee. Click OK.
You'll notice that some fields, like status and assignee, are still records. You'll need to expand them one more time to get the usable text value. For example, expand status and select the name field to get "To Do", "In Progress", or "Done". Expand assignee and select displayName to get the assignee's name.
After these steps, you'll have a clean, flat table of your Jira data, ready for building visuals in Power BI. Click Close & Apply in the top-left corner to load your data.
Advanced Tip: Managing Pagination
By default, the Jira API returns data in "pages" - usually 50 or 100 issues at a time. If your JQL query matches more issues than that, your Power Query will only pull in the first page. Solving this requires creating a function in Power Query to loop through all the pages of results. This is a more advanced topic, but in essence, you create a custom function that calls the Jira API, checks the total number of issues in the response, and then calls itself with an updated startAt parameter until it has fetched all the issues.
While this is a powerful technique, for many use cases with fewer than 100 active items, a single API call is often sufficient to start building meaningful reports.
Final Thoughts
Connecting Jira to Power BI via the API gives you unparalleled control to build the exact reports your team needs without extra costs. Once you get the hang of crafting a JQL query, handling the authentication token, and expanding nested JSON in Power Query, you unlock a highly flexible and cost-effective method for project analytics.
While this direct-access method is powerful, we know that spending time wrestling with API authentication, pagination, and data transformations isn't for everyone. We created Graphed specifically to eliminate this kind of manual reporting work. We automate the connection not just to Jira but to all your data sources like Google Analytics, Shopify, and Salesforce. Instead of building M queries, you just ask in plain language - "Show me a chart of completed story points by assignee this quarter" - and Graphed creates the live, interactive dashboard for you in seconds.