How to embed live chat box in a website

By default, the chatbox shows up on your website as a widget in the bottom-right corner.
In this guide, we will show how with minimum coding you can make rendering in an <div> anywhere on your website. It might be helpful if you decided to integrate the live chat on your support page, knowledge base, popup window, or in any special section.

Embed Chat Box

Here the chat box is shown right in the middle of the blog post. This is a real live chat with our customer service agents. Feel free to ask us any questions.

ChatBox HTML Source Code

Here is the code that made it happen, install it in the section of your website:

<script type="text/javascript">
      window.txtmeData = {
          settings: {
            chatToDiv: '#exampleDivId'
      (function (w,d,c,i) {
          var n = d.getElementsByTagName('script')[0],
              s = d.createElement('script');
          s.src = '' + i;
          s.type = 'text/javascript';
          s.async = true;
          n.parentNode.insertBefore(s, n);

The HTML code for the <div> where the chat box has shown up looks like this:

<div id="exampleDivId" style="width: 300px; height: 500px; margin:auto;box-shadow: rgba(164, 164, 164, 0.49) 0px 2px 24px;">

To finish the installation replace the exampleDivId with the id of the HTML element you want the widget to render to and replace the 000000000000000000000000000000 with the id number of your widget.

You can take it from the default HTML chat box code in your admin panel, which looks like this:

<!-- Start of widget code -->
<script src="" async></script>
<noscript><a href="" rel="nofollow">Rate customer support</a>, powered by <a href="" rel="noopener nofollow" target="_blank"></a></noscript>
<!-- End of widget code -->
Was this page helpful?
In this Article