Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Language Designator, Script Designator, Region Designator, Language ID, Locale ID all explained with examples.

Language Designator ISO 639-1

  • Specifies a language
  • 2-letters, lowercase
  • Ex:
en          English         
tr          Turkish         
ko          Korean

Script Designator ISO 15924

  • Specifies a writing system
  • 4-letters, first letter uppercase last three lowercase
  • Ex:
Latn        Latin       
Cyrl        Cyrillic    
Arab        Arabic

Region Designator ISO 3166-1

  • Specifies a country / territory / region
  • 2-letters, uppercase
  • Ex:
JP          Japan           
DE          Germany         
RU          Russian Federation

Language Tag RFC 5646

  • Specifies a language or a dialect of a language used in a country / territory / region, or a writing system of a language
  • In following formats:
 [Language Designator]                                              a language
 [Language Designator]-[Region Designator]                          a dialect of a language
 [Language Designator]-[Script Designator]                          a script of a language
 [Language Designator]-[Script Designator]-[Region Designator]      a script of a dialect of a language
  • Ex:
 hu               Hungarian
 fr-CA            Canadian French
 es-MX            Mexican Spanish
 de-CH            Swiss German
 it-CH            Swiss Italian
 az-Cyrl          Azerbaijani in Cyrillic script
 az-Latn          Azerbaijani in Latin script
 sr-Latn-RS       Serbian Serbian in Latin script 
 sr-Latn-BA       Bosnian Serbian in Latin script 

Locale ID Apple Convention

  • Specifies a pair: a language and a region's format conventions like date-time, number and currency
  • Not to be confused with POSIX Locale Identifier - ISO/IEC 15897
  • In following formats:
 [Language Designator]_[Region Designator]                          language and regional preference of user
 [Language Designator]-[Script Designator]_[Region Designator]      a script of a language and regional preference of user
  • Ex:
en_TR           English language with Turkey's format conventions
jp_US           Japanese language with United States of America's format conventions
zh-Hans_HK      Chinese in Simplified Script with Hong Kong's format conventions
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.