Step by step
Install the chat on your website
Copy the chat code from your agent’s Widget tab and paste it into your website. Includes the steps for a hand-built site and the guide for each platform.
- Reviewed on
- 4 min read
In this article
You install the chat by pasting one line of code into your website. Each agent has its own line, in its Widget tab: you copy it, paste it once, and the chat appears on every page that carries it.
Before you start
- The agent has to be active. An agent that is a Draft or is Paused does not show the chat even when the code is in place. Switch it on with the Activate button (or Resume, if it was paused) on the agent’s page.
- You need to be able to edit your website, or have someone who can: the person who built it, your agency or your platform’s support. The code and this article are all they need.
- The look does not have to be finished. Colours, the greeting and everything else can be changed later from the app without touching the website again. See customise the look of your website chat.
Copy your agent’s code
Go to Agents and open your agent.
Open the Widget tab and, inside it, Installation.
Under Installation code you will see a line like this one. Press Copy.
<script src="https://backendiagentify.yarqat.com/widget.js" data-agent="your-agent-key" async></script>Always copy the one in the app, not the one in this article: yours carries your agent’s public key, which is what tells the chat who answers.
Paste it into your website
The code goes just before the </body> tag, on every page where you want the chat. If your site uses one shared template for all its pages, pasting it once in that template is enough.
If your site is built with one of these platforms, follow its guide:
- Install the chat on WordPress
- Install the chat on Shopify
- Install the chat on Wix
- Install the chat on Squarespace
- Install the chat on Webflow
On a hand-built site (HTML)
Open the page’s file, for example
index.html, or the template all your pages share.Find the
</body>tag. It is almost at the end of the file.Paste the code on the line above it:
<!-- the content of your page --> <script src="https://backendiagentify.yarqat.com/widget.js" data-agent="your-agent-key" async></script> </body> </html>Save the file and publish it the way you always do: by FTP, from your hosting panel or with your deployment system.
Repeat the steps on any page that does not use that template.
On another platform or content manager
Look in its settings for an option called “custom code”, “code injection”, “scripts” or “footer” that adds code to the whole site before </body>, and paste the line there. If the platform only lets you add code to the header (<head>), that works too: the chat waits for the page to finish loading.
Check that it works
Open your website in a private browser window, so that you do not see a saved copy.
The chat button appears in a bottom corner of the page. Press it.
Type a question. The reply arrives within seconds and the conversation shows up under Conversations, inside the app.
After it is installed
- Changing the look or the texts. Whatever you change in the Widget tab applies when you press Save changes, without pasting the code again. On your website it can take about a minute to show.
- Switching agent. Each agent has its own code. To have a different agent look after your website, replace the line with the new agent’s.
- Removing the chat. Delete the line from your website. If you only want it to stop answering for a while, pause the agent: bear in mind that it then stops answering on WhatsApp and Instagram too.
If the chat does not appear
Most often the agent is not active, your domain is not under Allowed domains, or you are looking at an old copy of the page. The full list, with how to check each cause, is in the chat does not appear on your website.
Related articles
- Install the chat on WordPressPaste the chat code into your WordPress site with a header and footer code plugin or from the theme options, and check that it appears on your website.
- Customise the look of your website chatChange the chat’s texts, colours, button and the way it opens from your agent’s Widget tab, with a live preview and without touching your website again.
- Limit the chat to your domains, and whyWhile the allowed domains list is empty, any website can show your chat and use up your credits. How to fill it in, what each entry covers and what it does not protect.
- The chat does not appear on your website: what to checkIf the chat button does not show on your website, go through these causes in order: the agent, the code, the allowed domains, caching and whatever your site may be blocking.