# Add WebChat button to website

On this page, you will learn how to add the button directly into your website.

### Embedding in website - General

You can find the Javascript code for inserting the Mluvii button in the administration interface. Sign in with your email and password on the page <https://app.mluvii.com> as an administrator. In the section **“Settings - WebChat” you will see HTML code for inserting a script on pages,** which can be easily copied.&#x20;

You can also immediately check the widget settings on the **Test page** or in the **Preview** directly in the administration.

**Example of code for insertion:**

```js
<script type="text/javascript">
  (function () {
    var scr = document.createElement('script'); scr.type = 'text/javascript'; scr.async = true; scr.charset = 'UTF-8';
    scr.src = '//app.mluvii.com/widget/OOWidget.js';
    scr.$owidgetOnLoad = function (owidget) {
      if (!owidget.isSupported) { return; }
      owidget.init('295b1064-cf5b-4a5d-9e05-e7a74f86ae5e', '5652Mluvii1654');
      owidget.connectToServer();
    };
    var ffs = document.getElementsByTagName('script')[0]; ffs.parentNode.insertBefore(scr, ffs);
  })();
</script>
```

{% hint style="success" %}
*This code must be pasted into the tag`<head>`or`<body>`elements of a website, e.g. between tags`<head>`and`</ head>`. **The exact location of the code plays no role** in the placement of the widget. The script is downloaded asynchronously.*
{% endhint %}

{% hint style="danger" %}
*If you decide to implement a script for only a selected part of your site instead of covering the entire site, we strongly recommend that you create a second script without any visuals for use in the rest of the site.*
{% endhint %}

{% hint style="danger" %}
***The goal is to achieve 100% coverage of the site (by any mluvii script). This is the only way to make sure that an ongoing session doesn't abruptly end if the client is moving freely around your site.***
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.mluvii.com/en/for-it-specialists/add-webchat-button-to-website.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
