Skip to content
Tutorials Center
My learning

Topics

JavaScript Reference ยท Date and Intl

Date.prototype.toLocaleDateString()

Reference for JavaScript toLocaleDateString(): format the date part of a Date for any language and region, with options for weekday, month, dateStyle and timeZone.

toLocaleDateString() returns the date part of a Date as a string formatted for a language and region. The same day is written 3/15/2026 in the United States, 15/03/2026 in the United Kingdom, 15.3.2026 in Germany and 2026/3/15 in Japan. This method knows those rules, so you do not have to.

It takes a locale (or a list of locales) and an options object that picks which parts to show and in which style. Internally it uses Intl.DateTimeFormat.

JavaScript
const d = new Date(Date.UTC(2026, 2, 15));
d.toLocaleDateString("en-GB", { timeZone: "UTC" }); // "15/03/2026"

Try it

JS Same date, different locales

Press Run (or Ctrl + Enter) to see the console output here.

No output.

JS Options for each part

Press Run (or Ctrl + Enter) to see the console output here.

No output.

Syntax

JavaScript
date.toLocaleDateString()
date.toLocaleDateString(locales)
date.toLocaleDateString(locales, options)
Name Description
locales A BCP 47 language tag such as "en-US" or "de", or an array of tags. If omitted, the user's default locale is used.
options An object with the Intl.DateTimeFormat options. The common ones are weekday, year, month, day (each "numeric", "2-digit", "long", "short" or "narrow" where it makes sense), dateStyle ("full", "long", "medium", "short"), timeZone and calendar.

Return value: the formatted date as a string. For an invalid date, the string "Invalid Date".

Exceptions: a RangeError for an invalid locale tag or option value, and a TypeError if you combine dateStyle with individual fields, or ask for timeStyle.

Usage notes

  • Time zone matters. Without timeZone, the date is shown for the user's local zone. A moment near midnight UTC can be one day apart in different places. Pass timeZone: "UTC" (or a zone name such as "America/New_York") for a fixed result.
  • Default options show numeric year, month and day. Once you give any of weekday, year, month or day, only the fields you name are shown.
  • dateStyle is a shortcut that cannot be mixed with the individual fields.
  • Output depends on the engine. Locale data comes from the browser or runtime (ICU/CLDR), so punctuation and spacing can change between versions. Do not compare formatted strings in tests or parse them back.
  • Formatting many dates is faster with a formatter. Each call creates an Intl.DateTimeFormat internally. Create one with Intl.DateTimeFormat and reuse its format().
  • Use toLocaleTimeString() for the time part and toLocaleString() for both.
  • Do not send it to a server. Use toISOString() for data and locale methods for people.

Browser support

toLocaleDateString() works in every modern browser and runtime. The locales and options arguments are supported everywhere current, but the set of available locales can vary on older or minimal builds.