Does Weglot support Right To Left (RTL) languages?

In this article, you will learn how Weglot supports right-to-left (RTL) language translations.


Weglot supports RTL languages. It retains your original website's layout and HTML structure in the translated versions. Here are some of our available RTL languages:

  • Arabic (ar)
  • Hebrew (he)
  • Persian (fa)
  • or Urdu (ur) 

How do you customize the RTL language layout?


⚠️ First, please make sure that your theme supports Right-to-Left languages.

You can add custom CSS code that only applies to your RTL language(s). 

To do so, you'll need to go to your Weglot Dashboard > Project(s) > Settings > Language Switcher > then add the code below into the "CUSTOM CSS" field:

Here's the code:

html[lang="ar"] body {
       direction: RTL!important;
       text-align: right!important;
}
html[lang="ar"] .left {
      text-align: right!important;
}

Then click on "Save changes" and refresh your website

Please note that the code above is adapted for the Arabic language. If you need to use the same code for another RTL language, such as Hebrew, replace the language tag "ar" with "he" (or the corresponding language code).

Layout issues that may occur:


Sometimes, your pages may not display your RTL design correctly.

To fix that:

- Check with your web browser inspector that the CSS rule direction, rtl; applies to the content in question. If not, please add it to your Weglot Override CSS

- You could also try other CSS rules, such as:

  • float: right!important; align-content: right!important; 
  • or align-items: right!important;
Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.

Still need help? Contact Us Contact Us