Technology

W3C Publishes Draft Note on Language Tags and Locale Identifiers for the Web

W3C has published a Group Note Draft dated 20 November 2026 on definitions and best practices for language and locale tagging on the web, relevant to multilingual development teams.

By Oemah Solution Editorial 3 min read

This article was prepared with AI assistance from the official sources listed below, and checked automatically before publication.

Pink iMac with keyboard and mouse displayed on an exhibition table, with no people in the image
Photo: Jimmy Wales' Mac and the First Wikipedia Edit — "Hello World" (51738433963) by Steve Jurvetson from Los Altos, USA · CC BY 2.0 · Wikimedia Commons

W3C has published a Group Note Draft titled "Language Tags and Locale Identifiers for the World Wide Web", dated 20 November 2026. The document was prepared by the Internationalization Working Group, with Addison Phillips and Felix Sasaki, both Invited Experts, as editors. It contains definitions and best practices for identifying the natural language of content in document formats, specifications and implementations on the web.

Main contents of the document

According to W3C, language tags and locales are the foundation of web internationalisation (i18n). The document explains how language tags express a user's locale preferences, which are then used to process, format and display information.

Several points are covered:

  • Language tags in web formats and protocols are defined by BCP 47. Consistent use allows applications to perform language-specific processing, for example a browser choosing an appropriate font or a page designer styling text differently for each language.
  • Many core web standards support language tags, including the xml:lang attribute in XML, the lang and hreflang attributes in HTML, and the :lang pseudo-class in CSS.
  • A language tag consists of one or more subtags, which are sequences of ASCII letters or digits separated by hyphens and limited to a maximum of eight characters.
  • The IANA Language Subtag Registry serves as the machine-readable list of all valid subtags.

Best practices for specification authors

The document provides guidance, particularly for specification authors, including:

  • Specifications that require language identification must refer to BCP 47, not to its component RFCs.
  • Specifications must not refer to obsolete versions of BCP 47 such as RFC 1766 or RFC 3066. Where compatibility is needed, refer to the obs-language-tag production.
  • Applications that place language information in URIs should use BCP 47. W3C gives the example of German, which can be ambiguous between de (ISO 639-1) and ger (ISO 639-2), whereas the BCP 47 registry contains only de.
  • Specifications should not refer directly to the standards that underpin the registry, such as ISO 639 or UN M.49, unless they consume them directly.

Document status

W3C stresses that a Group Note Draft is not endorsed by W3C or its members, may be updated or replaced at any time, and is inappropriate to cite other than as work in progress. The W3C Patent Policy also places no licensing requirements on this document.

Relevance for organisations in Indonesia

Government portals, marketplaces and applications in Indonesia generally serve content in Indonesian, regional languages and English. Correct language tagging and locale handling relate to accessibility, search, date, number and currency formats, and pronunciation by screen readers. This W3C document does not address the Indonesian case specifically, but it can serve as a terminology reference.

Practical steps

  • Check whether the lang attribute is set on pages and on sections of content in a different language.
  • Use tags that are valid under BCP 47 and the IANA registry, rather than self-made codes.
  • Separate the content language from the user's locale preferences when formatting information.
  • Follow the progress of this draft through the w3c/ltli GitHub repository, as its contents may still change.
#w3c#internationalization#bcp47#web-standards#locale

Sources & references

This article is a summary and interpretation by the Oemah Solution team of the sources below. Refer to the original sources for full details and context.

  1. Language Tags and Locale Identifiers for the World Wide Web W3C · w3.org