Back to Material Ui

Localization

docs/data/material/guides/localization/localization.md

9.3.15.5 KB
Original Source

Localization

<p class="description">Localization (also referred to as "l10n") is the process of adapting a product or content to a specific locale or market.</p>

The default locale of Material UI is English (United States). If you want to use other locales, follow the instructions below.

Locale text

Use the theme to configure the locale text globally:

jsx
import { createTheme, ThemeProvider } from '@mui/material/styles';
import { zhCN } from '@mui/material/locale';

const theme = createTheme(
  {
    palette: {
      primary: { main: '#1976d2' },
    },
  },
  zhCN,
);

<ThemeProvider theme={theme}>
  <App />
</ThemeProvider>;

Example

{{"demo": "Locales.js"}}

:::warning The Data Grid and Data Grid Pro components have their own localization. :::

Supported locales

LocaleBCP 47 language tagImport name
Amharicam-ETamET
Arabic (Egypt)ar-EGarEG
Arabic (Saudi Arabia)ar-SAarSA
Arabic (Sudan)ar-SDarSD
Armenianhy-AMhyAM
Azerbaijaniaz-AZazAZ
Banglabn-BDbnBD
Bulgarianbg-BGbgBG
Catalanca-EScaES
Chinese (Hong Kong)zh-HKzhHK
Chinese (Simplified)zh-CNzhCN
Chinese (Taiwan)zh-TWzhTW
Croatianhr-HRhrHR
Czechcs-CZcsCZ
Danishda-DKdaDK
Dutchnl-NLnlNL
English (United States)en-USenUS
Estonianet-EEetEE
Finnishfi-FIfiFI
Frenchfr-FRfrFR
Germande-DEdeDE
Greekel-GRelGR
Hebrewhe-ILheIL
Hindihi-INhiIN
Hungarianhu-HUhuHU
Icelandicis-ISisIS
Indonesianid-IDidID
Italianit-ITitIT
Japaneseja-JPjaJP
Khmerkh-KHkhKH
Kazakhkk-KZkkKZ
Koreanko-KRkoKR
Kurdish (Central)ku-CKBkuCKB
Macedonianmk-MKmkMK
Myanmarmy-MYmyMY
Malayms-MSmsMS
Nepaline-NPneNP
Norwegian (bokmål)nb-NOnbNO
Norwegian (nynorsk)nn-NOnnNO
Pashto (Afghanistan)ps-AFpsAF
Persianfa-IRfaIR
Polishpl-PLplPL
Portuguesept-PTptPT
Portuguese (Brazil)pt-BRptBR
Romanianro-ROroRO
Russianru-RUruRU
Serbiansr-RSsrRS
Sinhalesesi-LKsiLK
Slovaksk-SKskSK
Spanishes-ESesES
Swedishsv-SEsvSE
Thaith-THthTH
Turkishtr-TRtrTR
Tagalogtl-TLtlTL
Ukrainianuk-UAukUA
Urdu (Pakistan)ur-PKurPK
Vietnamesevi-VNviVN
<!-- #target-branch-reference -->

You can find the source in the GitHub repository.

To create your own translation, or to customize the English text, copy this file to your project, make any changes needed and import the locale from there.

Please do consider contributing new translations back to Material UI by opening a pull request. However, Material UI aims to support the 100 most common locales, we might not accept contributions for locales that are not frequently used, for instance gl-ES that has "only" 2.5 million native speakers.

RTL Support

Right-to-left languages such as Arabic, Persian, Hebrew, Kurdish, and others are supported. Follow this guide to use them.