# Localization

Choose a Chat Box language to fit your business. You can change the language depending to the page user has opened. At the end of this page you can find a list of supported languages.

# Setup preferred (default) language

Add this little snippet to your code to change the language. In this case we setup English using code en in our script.

<script>
  smartsupp('language','en');
</script>

# Setup language dynamically

If you have multilanguage website, you can set the language in the same script. Expand code below using conditions and check your site URL for a language code. You can choose translations you need based on that. In this example you would look for /de/ or /cs/ or /en/in your URL (see the example code below) and set up the corresponding language depending on that.

  • http://example.com/de/
  • http://example.com/cs/
  • http://example.com/en/
<script>
if (window.location.href.indexOf("http://example.com/de/") > -1) { //choose URL
  smartsupp('language', 'de'); //set DE language
} else if (window.location.href.indexOf("http://example.com/cs/") > -1) { //choose URL
  smartsupp('language', 'cs'); // set CS language
} else {
  smartsupp('language', 'en'); // set EN language
}
</script>

# Supported languages

Are you missing your language in this list? You can help us translate Smartsupp widget! Just write us at support@smartsupp.com and we will provide you with further instructions. 😊

  • cs Czech (Czech Republic)
  • da Danish (Denmark)
  • de German (Germany)
  • en English (United States)
  • es Spanish (Spain)
  • fa Persian Farsi (Iran)
  • fr French (France)
  • hu Hungarian (Hungary)
  • it Italian (Italy)
  • lt Lithuanian (Lithuania)
  • nl Dutch (Netherlands)
  • pl Polish (Poland)
  • pt Portuguese (Portugal)
  • ro Romanian (Romania)
  • ru Russian (Russia)
  • sk Slovak (Slovakia)
  • sv Swedish (Sweden)
  • tr Turkish (Turkey)