How can I convert a date to YYYYMMDD format in Power BI?

To convert a date to YYYYMMDD format in Power BI, follow these steps:
1. Open your Power BI report or dashboard.
2. Click on the date column that you want to convert.
3. In the “Format” tab, select “Date” from the drop-down menu.
4. Scroll down and click on “More Formats”.
5. In the “Format options” window, select “YYYYMMDD” from the list.
6. Click “Apply” to save the changes.
7. The date column will now be displayed in YYYYMMDD format.
This format is useful for sorting and filtering dates in chronological order.

Power BI: Convert Date to YYYYMMDD Format


You can use the following syntax in DAX to convert a date to a YYYYMMDD format in Power BI:

Date_New = FORMAT('my_data'[Date], "YYYYMMDD")

The following example shows how to use this syntax in practice.

Example: Convert Date to YYYYMMDD Format in Power BI

Suppose we have the following table in Power BI named my_data that contains information about total sales made on various dates by some company:

Suppose we would like to convert the values in the Date column to a YYYYMMDD format.

To do so, click the Table tools tab, then click the icon called New column:

Then type the following formula into the formula bar:

Date_New = FORMAT('my_data'[Date], "YYYYMMDD")

This will create a new column named Date_New that shows each of the corresponding date values from the Date column represented as text values in the format YYYYMMDD:

For example:

  • January 1, 2024 is shown as 20240101.
  • January 5, 2024 is shown as 20240105.
  • February 15, 2024 is shown as 20240215.

And so on.

Note: You can find the complete documentation for the FORMAT function in DAX .

Additional Resources

The following tutorials explain how to perform other common tasks in Power BI:

x