---
schema_version: "1"
id: 2d29690d1d863f3b2de5618b58b6a1ca1f68af1371cfe10ad9cf1faba91c6446
title: $Locale
collection: developer
version: current
locale: en-us
portal_url: https://docs.salesforce.com/developer/current/en-us/platform/aura-platform/guides/aura/expr/expr-locale-value-provider.md
canonical_url: https://developer.salesforce.com/docs/platform/aura-platform/guide/expr-locale-value-provider.html
source_site: developer.salesforce.com
content_type: documentation
content_hash: db237d86d08a60fff45bc857bf2d9b8bb59cc7131cbb8d54229c32832397057f
products:
  - Lightning Aura Components Developer Guide
  - Platform Developer Content
---

# $Locale

The `$Locale` global value provider returns information about the current user’s preferred locale.

|Attribute|Description|Sample Value|
|---------|-----------|------------|
|`country`|The ISO 3166 representation of the country code based on the language locale.|"US", "DE", "GB"|
|`currency`|The currency symbol.|"$"|
|`currencyCode`|The ISO 4217 representation of the currency code.|"USD"|
|`decimal`|The decimal separator.|"."|
|`firstDayOfWeek`|The first day of the week, where 1 is Sunday.|1|
|`grouping`|The grouping separator.|","|
|`isEasternNameStyle`|Specifies if a name is based on eastern style, for example, `last name first name [middle] [suffix]`.|false|
|`labelForToday`|The label for the Today link on the date picker.|“Today”|
|`language`|The language code based on the language locale.|"en", "de", "zh"|
|`langLocale`|The locale ID.|“en_US”, “en_GB”|
|`nameOfMonths`|The full and short names of the calendar months|{ fullName: “January”, shortName: “Jan” }|
|`nameOfWeekdays`|The full and short names of the calendar weeks|{ fullName: “Sunday”, shortName: “SUN” }|
|`timezone`|The time zone ID.|"America/Los_Angeles"|
|`userLocaleCountry`|The country based on the current user’s locale|“US”|
|`userLocaleLang`|The language based on the current user’s locale|“en”|
|`variant`|Deprecated. The variation for a language dialect.| |

## Number and Date Formatting

|Attribute|Description|Sample Value|
|---------|-----------|------------|
|`currencyFormat`|The currency format.|"¤#,##0.00;(¤#,##0.00)" ¤ represents the currency sign, which is replaced by the currency symbol.|
|`dateFormat`|The date format.|"MMM d, yyyy"|
|`datetimeFormat`|The date time format.|"MMM d, yyyy h:mm:ss a"|
|`longDateFormat`|The long date format.|"MMMM d, yyyy"|
|`numberFormat`|The number format.|"#,##0.###" # represents a digit, the comma is a placeholder for the grouping separator, and the period is a placeholder for the decimal separator. Zero (0) replaces # to represent trailing zeros.|
|`percentFormat`|The percentage format.|"#,##0%"|
|`shortDateFormat`|The short date format.|"M/d/yyyy"|
|`shortDatetimeFormat`|The short date time format.|"M/d/yyyy h:mm a"|
|`shortTimeFormat`|The short time format.|"h:mm a"|
|`showJapaneseCalendar`|Specifies whether to show dates in the Japanese Imperial calendar format|false|
|`timeFormat`|The time format.|"h:mm:ss a"|
|`zero`|The character for the zero digit.|“0”|


## Example

This example shows how to retrieve different `$Locale` attributes.

**Component source**

<!-- otherprops: set_clipboard -->
```nolang
<aura:component>
    {!$Locale.language}
    {!$Locale.timezone}
    {!$Locale.numberFormat}
    {!$Locale.currencyFormat}
</aura:component>

```

Similarly, you can check locale information in JavaScript using `$A.get()`.

```javascript
({
    checkDevice: function(component) {
        var locale = $A.get("$Locale.language");
        alert("You are using " + locale);
    }
})
```

**See Also**  


-   [Localization](https://developer.salesforce.com/docs/platform/aura-platform/components/components-l10n.md)

