Help › Install on your site

Install with the script tag

BuiltLast updated

On this page

The script tag works on any website. It needs no server changes. The loader translates the page in the visitor's browser. If anything fails, the visitor sees your original text.

The tag#

<script async src="https://cdn.example/loader/v1/loader.js"
        data-site-key="rl_site_live_..."
        data-public-key="..."></script>

Do not copy this example. The dashboard's install page has ready guides for the script tag, Wix and Squarespace. Open your site in the dashboard, choose Install, and copy the tag that already holds your real values. If the dashboard says the snippet is not available, an administrator still has to set the loader address and the public key. The page shows a snippet only when it would work.

The attributes#

AttributeNeededMeaning
data-site-keyYesYour public site key.
data-public-keyYesThe public key that checks the signature of your files. You may list two keys, separated by a space, while a key is being replaced.
data-baseNoMore places to load files from. Secure addresses only.
data-timeoutNoHow long to wait for each place, in milliseconds. The default is 2500.
data-suggestNotrue lets the loader announce the browser's language as a suggestion. It never switches the page by itself.

There are no other attributes. A secret API key (rl_sec_...) must never be used here.

Where to paste it#

Paste it into the <head> of every page, once, in the shared layout. Platform steps: Wix, Squarespace, Webflow, single-page apps.

Test it#

  1. Publish your site and open it in a private window.
  2. Pick a language in the switcher and reload. Your choice is remembered in that browser.
  3. Open the browser tools, block the host that serves the translation files, and reload. The page must show your original language, not an error.

Optional: pin the script#

You can add an integrity check, but only to a numbered, fixed loader address. Never add it to the /loader/v1/loader.js address, which changes with each release. A pinned hash would stop the loader every time it is updated, and the page would stay untranslated. The real loader address is OPEN until the delivery domain exists.

Search engines#

Read SEO and the script tag before you promise anyone search traffic in other languages.