Web widget
The web widget puts a chat button on your website. Messages from visitors open conversations in Kontakt, where your AI agent and team pick them up.
The web widget is a chat button and panel you add to your website with one line of code. Each visitor's messages open a Web Widget conversation in Conversations, and the AI agent bound to the widget handles them. Replies from the AI agent and from your team appear in the visitor's chat panel. Web widget messages have no channel charge. AI replies cost 3 credits each.
Before you start
- A role that can change workspace settings.
- Access to your website's HTML, or a tag manager, to add a script tag.
- An AI agent to answer website chats. See Agents.
Set up the widget
Open Web Widget settings
Go to Settings / Web Widget.
Brand it
Set the Position (Bottom right or Bottom left), the Primary color (pick a swatch or type a HEX code), the Welcome message shown at the top of the panel, and an optional Logo. The Live preview updates as you change them.
Add your domains
Under Allowed domains, enter the hostnames where you'll install the widget, separated by commas, for example example.com, www.example.com. Only pages on these hostnames can show the widget and send messages. Leave the field empty to allow any website, which is handy while you test.
Enable and save
Set Enabled to Enabled and click Save Widget. While the widget is disabled, the snippet loads but visitors can't start a chat.
Copy the snippet
Under Embed snippet, click Copy. Paste the snippet before the closing body tag on every page where the chat button should appear, or add it through your tag manager.
Bind an AI agent
Open the agent in AI / Agents and, under Channel connections, tick the connection listed in the Web widget group.
Test it
Open your site, click Chat, and send a message. The agent's reply appears in the panel, and the chat shows in Conversations as a Web Widget conversation. Reply from Conversations and check that your reply reaches the panel too.

The snippet
The snippet is a single script tag. It carries your workspace ID and the position you chose:
<script src="https://<kontakt-api-host>/widget/v1/loader.js"
data-workspace="<your-workspace-id>"
data-api-base="https://<kontakt-api-host>/api/v1"
data-position="bottom-right"></script>
Always copy the real snippet from Settings rather than typing it. Branding, the welcome message, and position load from your saved settings each time the page opens, so you don't need to change the snippet after you edit them.
How it behaves
- Visitors. A visitor's first message creates a person named Website Visitor in People. Opening the panel without sending anything creates nobody. Visitors don't log in, so Kontakt doesn't know who they are unless they tell you in the chat.
- Sessions. The widget remembers the visitor in their browser for 30 days. If they reload the page, move to another page on your site, or come back later, the panel shows their earlier messages and new messages go to the same person and conversation. Another browser or device, a private window, or clearing site data starts a new session.
- Replies. After a visitor sends a message, the panel shows a typing indicator until a reply arrives, for up to 90 seconds. AI replies and replies your team sends from Conversations both appear in the panel, with your teammate's first name above their messages. Replies usually show within a few seconds while the panel is open. If the panel is closed, the Chat button shows a count of unread replies.
- Allowed domains. When the list has entries, the widget only loads and accepts messages on pages whose hostname matches one exactly. www.example.com and example.com are different hostnames, so list both if you use both. To cover every subdomain, add an entry like
*.example.com. Pages on other sites don't show the chat button. - Conversations. Website chats show the Web Widget channel in Conversations.
- AI timing. The AI waits about two seconds after a message before replying, so a visitor who sends several short messages gets one answer.
- Message limits. A message can be up to 4,000 characters. A visitor who sends more than 20 messages in a minute is asked to wait.
- Routing. New website conversations follow your auto-assignment rules like other channels. See Routing.
- Text only. Visitors can send text. The widget doesn't accept files.
Troubleshooting
The chat button doesn't appear
Check that the snippet is on the page and that the browser console shows no "[Kontakt Widget] data-workspace is required" error. Copy the snippet again from Settings if in doubt.
If the console says the website is not in the widget Allowed domains, add the page's hostname under Allowed domains and click Save Widget, or clear the list.
"Chat is unavailable right now."
The widget is disabled. Set Enabled to Enabled and click Save Widget.
"Chat is not available on this website."
The page's hostname isn't in Allowed domains. Add it, including the www. form if your site uses it, and save.
"Message failed. Please try again."
The message didn't reach Kontakt. Check the visitor's connection and that the widget is still enabled. The message text goes back into the input box so the visitor can send it again.
"You are sending messages too quickly."
The visitor sent more than 20 messages in a minute. They can send again after a short wait.
Chats arrive but the AI doesn't answer
Check that an agent has the widget ticked under Channel connections. An agent with no connections selected doesn't answer live traffic. If a teammate has taken over the conversation, the AI stays quiet and the typing indicator stops after 90 seconds.
Hosted chat page
The hosted chat page is a public link, created during onboarding, where visitors chat with your agent without you adding anything to your website. It behaves like the widget: replies from the agent and your team appear on the page, a typing indicator shows while a reply is on its way, and the browser remembers the visitor for 30 days so a reload continues the same conversation. Its chats land in Conversations like other channels, and visitors appear in People as Chat Visitor. Allowed domains doesn't apply to the hosted chat page, because the page runs on Kontakt.