Still have questions?
Contact support
You are looking at an outdated 7.10.0 version of this document. Switch to the 7.12.0 version to see the up to date information.



AnyChart Gantt charts support full localization of input and output date time and number formats using locale mechanism. Using locales is really easy and this article will tell you how.

Applying automatic locale

You can use locales created by AnyChart for the most regions and cultures, do that, first link a file from AnyChart CDN or download it on your server and link from there.

Linking from CDN looks like this:

<script src="">
<script src="">

Linking from your server may look like this:

<script src="./locales/english-(united-kingdom).js">
<script src="">

After you linked the file AnyChart engine knows about it and you can start using it in your AnyGantt charts, just set the code of the locale in either inputLocale or outputLocale. The code of the locale is listed in the CODE column on AnyChart Locales CDN.

Setting input and output locale looks like this:


And that's how it works, you can see that names of the month in the timeline changed to Hindu:

JsFiddle Playground

Tuning locale

Locales define the default input and output date time format, but you can tune this using inputDateTimeFormat and {api:anychart.format#outputDateTimeFormat{api} if you want to use input or output format alternative to the locale:

// set locales

// tune inputDateTimeFormat and outputDateTimeFormat
anychart.format.outputDateTimeFormat('dd MMM');

And that's how it will work:

JsFiddle Playground

Locales CDN

You can get all available locales from AnyChart CDN. You can both download them to your server or reference directly from CDN.