• Products
  • Documentation
  • Resources

Custom date formatting

For charts with date or datetime axes, Atlassian Analytics has pre-defined formats that you can choose from to display those dates and times in your chart’s axis labels. If you don’t see a pre-defined option that meets your needs, you can provide a custom date format to use in your chart’s axis labels. Custom date formats let you specify the exact way you want to display your date labels in the chart.

To use a custom date format:

  1. Open the chart settings of the chart.

  2. Go to the Axis tab.

  3. For Date format of your date axis, select Custom.

  4. Provide a format string using any of the format directives listed below. The default format string is %Y-%m-%d.

Atlassian Analytics uses the d3-time-format module to power its custom date formatting. View the d3 Github documentation for all available formatting options.

Applying a custom date format of '%m/%d/%Y' to show month, day, then year.

Examples of format strings

Use any of these common format strings for your custom date format:

  • %m/%d/%Y separates the month, day, and year by a forward slash (/)—for example, 01/31/2022.

  • Q%q shows the quarters as Q1, Q2, Q3, or Q4.

  • %-m/%-d shows month and day without prepended 0s. For example, January 2nd would show as 1/2.

  • %b %_d, %y shows dates as Feb 4, 22 for example.

  • %d.%m.%y separates the day, month, and year by a period (.)—for example, 31.01.2022. Switch the order around and notation for a Spanish date system.

Available format directives

Directives return the desired part of a date or timestamp. Use a combination of static text and any of the following directives to create your custom format string:


Part of date


Example output

Abbreviated weekday names


Sun, Mon, Tue, Wed, Thu, Fri, Sat

Full weekday names


Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday

Weekdays as numbers (Sunday-based)


0, 1, …, 6

Weekdays as numbers (ISO 8601 Monday-based)


1, 2, …, 7

Zero-padded days


01, 02, …, 31

Space-padded days


1, 2, …, 31

Abbreviated month names


Jan, Feb, Mar, Apr, May, Jun, Jul, Aug, Sep, Oct, Nov, Dec

Full month names


January, February, March, April, May, June, July, August, September, October, November, December

Months as numbers


01, 02, …, 12

Years with the century


2000, 2001, 2002, and so on

Years without the century


00, 01, …, 99

Weeks of the year (Sunday-based)


00, 01, … 53

Note that all days in a new year preceding the first Sunday are considered to be in week 0.

Weeks of the year (Monday-based)



00, 01, … 53

Note that all days in a new year preceding the first Monday are considered to be in week 0.

Day of the year


001, 002, … 366

Quarter of the year


1, 2, 3, or 4


Part of time


Example output

24-hour clock


0, 1, …, 23

12-hour clock


1, 2, … 12



00, 01, … 59



00, 01, …, 61

Note that the range for seconds goes up to 61 rather than 59 to allow for the occasional leap second and double leap sound.



000, 001, … 999

a.m. or p.m.


AM or PM

Milliseconds since UNIX epoch



Seconds since UNIX epoch




Still need help?

The Atlassian Community is here for you.