---
schema_version: "1"
id: 13911821bde64722626b47cafaa8699f79434d8d8b950959ed1640856a4e1cd1
title: Set a Bot Conversation Language
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/service/264-0-0/bots_service_language_set.md
canonical_url: https://help.salesforce.com/s/articleView?id=service.bots_service_language_set.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: 9e9a6dce874dd3c2c76ff464f632d7f9c16dacaeec52c7c8e10889fe75781b14
description: You can easily define a bot conversation language at the beginning of the conversation. End users can then select their preferred language and switch to the translated text. You can also set the preferred language variable using browser information or based on a URL.
products:
  - Service Cloud
  - Service Intelligence
release: "264"
---
# Set a Bot Conversation Language

You can easily define a bot conversation language at the beginning of the conversation. End users can then select their preferred language and switch to the translated text. You can also set the preferred language variable using browser information or based on a URL.

### Required Editions

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small edition"><colgroup><col></colgroup><tbody><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;"><a href="https://help.salesforce.com/s/articleView?id=service.einstein_service_intro.htm&amp;language=en_US" target="_blank">View supported editions</a>.</td></tr></tbody></table>

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small permission">
        <colgroup>
          <col style="width:50%">
          <col style="width:50%">
        </colgroup>
        <thead class="slds-text-title_caps ">
          <tr class="">
            <th scope="colgroup" class="slds-cell-wrap" colspan="2" style="text-align:center;vertical-align:top;" id="d40917e57">User Permissions Needed</th>
          </tr>
        </thead>
        <tbody>
          <tr class="">
            <td data-label="User Permissions Needed" class="slds-cell-wrap" style="vertical-align:top;" headers="d40917e57 ">To build and manage Einstein Bots:</td>

            <td class="slds-cell-wrap" style="vertical-align:top;" headers="d40917e57 ">
              <p>Customize Application</p>
              <p>OR</p>
              <p>Modify Metadata</p>
              <p>OR</p>
              <p style="margin-bottom:0;">Manage Bots</p>
            </td>

          </tr>
        </tbody>
      </table>

For bots with multiple languages, set the preferred language as early as possible in the conversation to deliver an immersive experience. You can create a variable to store the language and add a dialog to manually set it inside the conversation.

You can also write custom code to define the preferred language based on data from the source website or browser metadata. If you code to set the language in the background, include a dialog to manually change the language if the set language is incorrect.

To create a bot conversation language selection dialog:

1. In the Bot Builder menu, select **Variables**. Click **New**.
2. Create a variable with a Custom Type and a Text Data Type, and then save your changes.
3. In the Bot Builder menu, select **Entities**. Click **New**.
4. Create an entity with a Data Type of Text and Extraction Type of Value, and then save your changes.
5. Click the name of your new entity. Set your primary language as the active language using the language dropdown.
6. To add values, click **Add** next to Value List.
    
    ![You can add many languages to one value.](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-service-support_intelligence-264-0-0-production-enus/dcd06a7b-b5ab-448b-a767-4e2e90481508/support_intelligence/images/bots/bots_service_multilang_entity.png)
7. Enter a value and an alternative value for each supported language. Make sure that the value matches the language code of the supported languages, as they’re the same across all languages. The alternative values, separated by commas, define ways that the language can be entered by an end user. Einstein Bots only supports translations for the languages listed in [Set or Update a Bot Primary Language](https://help.salesforce.com/s/articleView?id=service.bots_service_language.htm&release=264.0.0&type=5 "Every Einstein Bot requires a primary language to be able to understand your end users. Defining a bot primary language helps with natural language processing (NLP) and named entity recognition (NER).").
8. Change the active language to each secondary language, and provide values and alternate values.
9. In the Bot Builder menu, select **Dialogs**. Click ![To add a new dialog, use the plus icon in the dialog list.](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-service-support_intelligence-264-0-0-production-enus/dcd06a7b-b5ab-448b-a767-4e2e90481508/support_intelligence/images/bots/bots_service_plus_dialog.png), and then **New Dialog**.
10. To add a question dialog step, click ![Add a new dialog step using the plus icon.](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-service-support_intelligence-264-0-0-production-enus/dcd06a7b-b5ab-448b-a767-4e2e90481508/support_intelligence/images/bots/bot_service_dialog_element.png) in the dialog, then select **Question**.
11. In the Bot Asks field, ask the end user to select their preferred language. Select the custom entity and variable.
    
    ![Add a question dialog step with language choices.](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-service-support_intelligence-264-0-0-production-enus/dcd06a7b-b5ab-448b-a767-4e2e90481508/support_intelligence/images/bots/bots_service_multilang_question.png)
12. In Choice Type, select Static, and include options for all available languages.
    
    ![Note](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-service-support_intelligence-264-0-0-production-enus/dcd06a7b-b5ab-448b-a767-4e2e90481508/images/icon_note.png)
    
    Note
    
    The static options include one of the alternative values from your entity. Including multiple variations of alternative values covers cases where the end user chooses not to select the static choices and types in a value instead.
13. Add a Rule Dialog Step without a condition. Select **Set Conversation Language** as the Rule Action and your custom variable as the Variable Name.
14. Add a message dialog step with a message confirming the language has been set to the selected language.
    
    ![To set the conversation language, add a rule dialog step.](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-service-support_intelligence-264-0-0-production-enus/dcd06a7b-b5ab-448b-a767-4e2e90481508/support_intelligence/images/bots/bots_service_multilang_rule_mesage.png)
15. In the Next Step section, select **Start another dialog**, select the **Main Menu** dialog, and then save your changes. To enter secondary language translations, change your active language to each secondary language, and click into the Dialog Translations tab. Save your changes.
    
    ![Translate your language selection text into all included languages.](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-service-support_intelligence-264-0-0-production-enus/dcd06a7b-b5ab-448b-a767-4e2e90481508/support_intelligence/images/bots/bots_service_multilang_translate_selection.png)