How to sort Power BI chart x axis by month & date?

Here’s a question from Emilio:

I loaded an Excel spreadsheet to my Power BI desktop app, and inserted a stacked chart visual. When looking at the x axis i see it is sorted our in a wrong order – in my case alphabetically – which doesn’t make much sense. How can i arrange the axis labels in a chronological descending order. Any pointers here.

Order Power BI chart axis chronologically

To sort your Power BI visual x-axis by month name, follow the steps outlined in this tutorial:

  • In Power BI Desktop, hit the Insert button and then go ahead and pick the New Visual option.
  • Next, drag the required fields into the visual. In this example we will analyze the Course Revenues by calendar month, so we will drag the Month into the X Axis and Sum of Order Amount into the Y Axis of our visual.
  • Note: You can alternatively create a stacked chart by inserting more fields into your bar chart legend.
  • As you can see, our column chart is ordered by the Order amount – however in descending order.
  • Luckily we can fix this issue very easily: hover with your mouse over the upper right side of our visual and you will find the More Options button (3-dots).
  • Hit the More Options button and select Sort Axis.
  • The select your Date field (in our case Month).
  • Now, your months will be sorted in descending order which is not too helpful.
  • Hit again on More Options but now pick the Sort in Ascending Order option.
  • Your column chart should look as following: