How to Sort Bar Chart in Power BI?

Do you work in Power BI and don’t know how to sort bar charts? In this article, I will help you understand how to sort bar chart in Power BI report with an example.

How to Sort Bar Chart in Power BI

When we create a bar chart, you must see, by default, that it is sorted by values in descending order, but we can sort it in ascending order in simple steps.

How to Sort Bar chart in Power BI

Here, I connected the SharePoint List to Power BI Desktop. If you don’t know how to connect the SharePoint List to Power BI, click here.

Here is the SharePoint list that I am using for this Bar chart. You must have a SharePoint list before creating and sorting the bar chart. See the screenshot below:

Sort bar chart in Power BI

1. Now select the stacked bar chart under the visualization panel.

power bi sort columns alphabetically

2. I want to show the “Sum of sales by Product Name”. So, drag “Product Name” into the “Y-axis” and then drag “Sales” into the “X-axis” field. Here, choose the value as Sum of Sales as shown in the figure below:

how to sort bar chart in power bi

3. Select the bar chart. Click on the upper-right side of our visual. You will find the More Options (3 dots) button. Then, the dialog box opened. In the dialog box, click “Sort axis”.

How to Sort Bar Chart values in Power BI

“Product Name” means the alphabet, and “Sum of Sales” means value. We can sort by value (ascending/descending) or alphabet (ascending/descending).

4. Select “Product Name” and “Sort ascending” and see the changes in the screenshot below.

Sort the bar chart example in Power BI

Here, you see the above bar chart sorted in alphabetical ascending order.

5. Select “Product Name” and “Sort descending” and see the changes in the screenshot below.

power bi sort columns alphabetically descending order

This way, we can sort the bar chart in Power BI Desktop.

Conclusion

I hope you follow the above steps to sort the bar chart in Power BI. In this tutorial, we learned how to ascend or descend sort the bar chart in Power BI Desktop.

Also, you may like some more Power BI tutorials: