Can metadata values be language-specific in DITA?

Yes, metadata values can be language-specific in DITA. This allows content creators to provide metadata in multiple languages, ensuring that metadata is tailored to the linguistic and cultural preferences of different audiences.

DITA supports the inclusion of metadata values in different languages. This means that metadata elements, such as titles, descriptions, or keywords, can have variations in different languages to cater to diverse audiences. This is highly useful for localization in general, managing metadata elements, and managing localized attributes and elements.


Language-specific metadata is crucial for localization efforts. For example, if a product manual targets both English-speaking and French-speaking audiences, metadata can be provided in English and French to ensure that the metadata is contextually relevant.

Metadata Elements:

Common metadata elements that can have language-specific values include titles, descriptions, keywords, and any other metadata attributes that might change based on the target language.

Attributes and Elements:

In XML-based DITA documents, attributes like xml:lang can be used to specify the language of specific elements or attributes within the document, including metadata. This helps tools and systems identify the intended language.


            <!-- English Metadata -->
            <title xml_lang="en-US">Product User Guide</title>
            <description xml_lang="en-US">Comprehensive guide for product usage.</description>
            <keywords xml_lang="en-US">user guide, product documentation</keywords>

            <!-- French Metadata -->
            <title xml_lang="fr-FR">Guide de l'utilisateur du produit</title>
            <description xml_lang="fr-FR">Guide complet pour l'utilisation du produit.</description>
            <keywords xml_lang="fr-FR">guide de l'utilisateur, documentation du produit</keywords>

In this example:

  • Metadata elements (<title>, <description>, and <keywords>) have language-specific values provided for both English (en-US) and French (fr-FR).
  • The xml:lang attribute is used to specify the language associated with each metadata value, ensuring that metadata is presented in the appropriate language based on the audience’s preferences or localization requirements.