W3docs

ISO Language Codes

ISO Language Codes-The lang attribute is used to declare the language of a web page or a part of a web page. See the list of language codes by countries.

ISO Language Codes

The HTML lang attribute declares the language of a web page or a part of a web page. It helps search engines and browsers process content correctly.

The W3C recommends declaring the primary language for every web page using the lang attribute inside the <html> tag.

See how to do it below:

The HTML lang attribute is used to declare the language of a web page or just a part of a web page

<html lang="hy">
...
</html>

See how it must be in XHTML below:

How to use HTML lang attribute in XHTML

<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
...
</html>

Modern HTML uses BCP 47 language tags, which extend ISO 639-1 with region or script subtags (e.g., en-US, zh-Hans).

ISO 639-1 Language Codes

ISO 639-1 defines two-letter language abbreviations.

See the list of ISO 639-1 language codes:

LanguageISO Code
Abkhazianab
Afaraa
Afrikaansaf
Albaniansq
Amharicam
Arabicar
Aragonesean
Armenianhy
Assameseas
Aymaraay
Azerbaijaniaz
Bashkirba
Basqueeu
Bengali (Bangla)bn
Dzongkhadz
Biharibh
Bislamabi
Bretonbr
Bulgarianbg
Burmesemy
Belarusianbe
Cambodiankm
Catalanca
Cherokee-
Chewa-
Chinesezh
Chinese (Simplified)zh-Hans
Chinese (Traditional)zh-Hant
Corsicanco
Croatianhr
Czechcs
Danishda
Divehi-
Dutchnl
Edo-
Englishen
Esperantoeo
Estonianet
Faeroesefo
Farsifa
Fijifj
Finnishfi
Flemish-
Frenchfr
Frisianfy
Fulfulde-
Galiciangl
Gaelic (Scottish)gd
Gaelic (Manx)gv
Georgianka
Germande
Greekel
Greenlandickl
Guaranign
Gujaratigu
Haitian Creoleht
Hausaha
Hawaiian-
Hebrewhe
Hindihi
Hungarianhu
Ibibio-
Icelandicis
Idoio
Igbo-
Indonesianid
Interlinguaia
Interlingueie
Inuktitutiu
Inupiakik
Irishga
Italianit
Japaneseja
Javanesejv
Kannadakn
Kanuri-
Kashmiriks
Kazakhkk
Kinyarwanda (Rwanda)rw
Kirghizky
Kirundi (Rundi)rn
Konkani-
Koreanko
Kurdishku
Laothianlo
Latinla
Latvian (Lettish)lv
Limburgish (Limburger)li
Lingalaln
Lithuanianlt
Macedonianmk
Malagasymg
Malayms
Malayalamml
Maltesemt
Maorimi
Marathimr
Mongolianmn
Nauruna
Nepaline
Norwegianno
Occitanoc
Oriyaor
Oromo (Afaan Oromo)om
Papiamentu-
Pashto (Pushto)ps
Polishpl
Portuguesept
Punjabipa
Quechuaqu
Rhaeto-Romancerm
Romanianro
Russianru
Sami (Lappish)-
Samoansm
Sangosg
Sanskritsa
Serbiansr
Serbo-Croatiansr / hr / bs
Sesothost
Setswanatn
Shonasn
Sichuan Yiii
Sindhisd
Sinhalesesi
Siswatiss
Slovaksk
Sloveniansl
Somaliso
Spanishes
Sundanesesu
Swahili (Kiswahili)sw
Swedishsv
Syriac-
Tagalogtl
Tajiktg
Tamazight-
Tamilta
Tatartt
Telugute
Thaith
Tibetanbo
Tigrinyati
Tongato
Tsongats
Turkishtr
Turkmentk
Twitw
Uighurug
Ukrainianuk
Urduur
Uzbekuz
Venda-
Vietnamesevi
Volapükvo
Wallonwa
Welshcy
Wolofwo
Xhosaxh
Yi-
Yiddishyi
Yorubayo
Zuluzu

Practice

Practice

From the listed options, which are valid HTML language codes according to the website https://www.w3docs.com/learn-html/html-language-codes.html?