Guides

How to add a chatbot to your Wix website in 10 minutes

Adding a chatbot to Wix takes one pasted script. Follow the steps to train your agent, add the code, test on desktop and mobile, and fix the usual problems.

By the Askocto team · · 5 min read

To add a chatbot to a Wix website, you create and test the chatbot in your support platform, copy its embed script and paste it into Wix as a custom code snippet that loads on every page. The whole job takes about ten minutes once your agent is ready. This guide covers the steps, a test routine and fixes for the usual problems. The menu names in Wix can change, so look for the equivalent labels if yours differ.

In short: Train the agent, copy the embed script, add it in Wix under custom code for the whole site, publish and test on a phone.

What you need before you start

  • A Wix site on a plan that allows custom code. Check this in your Wix account if the option is missing.
  • A chatbot with content and a test conversation or two behind it.
  • Access to your site's dashboard as an owner or someone with permission to edit settings.

Do the chatbot first. Adding an empty bot to a live site shows visitors a chat window that cannot help. The guide to adding an AI chatbot to your website has a ten-step plan for the preparation, and the best AI chatbots for Wix websites page can help you choose one.

Step 1: get your embed script

In Askocto, open your agent and go to Channels, then choose the website widget. Copy the script. It looks like this, with your own agent id:

<script src="https://cdn.askocto.co/embed.js" data-agent-id="agt_123" defer></script>

Other platforms give you a similar one-line snippet. Keep it ready on your clipboard.

Step 2: paste it into Wix

  1. Open your Wix dashboard and select your site.
  2. Go to Settings and find Custom code (it may sit under advanced settings).
  3. Choose to add new code, and paste the script.
  4. Name it something clear such as "Support chatbot".
  5. Set it to load on All pages.
  6. Choose to place it in the Body, end section if the option exists, or the head with the script's defer attribute kept as is.
  7. Apply the change.

Then open the editor and Publish the site. Custom code does not show on the live site until you publish.

Step 3: test on your live site

Open your site in a private browser window, so you see what a visitor sees.

  1. Does the chat bubble appear in the corner within a few seconds?
  2. Click it. Does the greeting show?
  3. Ask three real questions from your content. Are the answers right?
  4. Ask one question that is not in your content. Does the bot say it does not know and offer a person?
  5. Try the handover path: ask for a human and check what happens.

Step 4: check mobile

Most Wix traffic arrives on phones. Open the site on a real phone and look for:

  • The bubble overlapping a cookie banner or a Wix chat button. Move or turn off the one you do not need.
  • The chat window covering the main call to action when open.
  • Text that is hard to read at small sizes.

If you have another chat tool on Wix, remove it before you add this one. Two bubbles in the same corner confuse visitors.

Show it only where it helps

You may not want the chatbot on every page. Options:

Goal How
Hide on the checkout or a landing page Add the code to selected pages instead of all pages
Open automatically on the pricing page Use the widget settings or the window.askocto.open() call on that page
Show a first message on a product page Use a custom initial message in the widget settings

The widget script also supports a page context, so the agent knows which page the visitor is on. See the website integration docs for the full list of options.

Common problems and fixes

  • Nothing appears. Confirm you published, that custom code is set to all pages, and that your plan allows custom code. Check that you pasted the whole snippet, including the closing tag.
  • It appears in the editor only. Custom code loads on the live site, not always in the editor preview. Test the published URL.
  • It loads twice. You probably pasted the script in two places. Remove one.
  • The agent id is wrong. The id starts with agt_. Copy it again from the channel page.
  • A cookie banner blocks it. Some consent tools hold back scripts until a visitor agrees. Check your consent settings.

After it is live

Look at the first conversations the same day. Note the questions the agent could not answer, add them to your content and test again. Review once a week for the first month. The guide on testing an AI support agent before launch explains how to keep a standard set of questions to rerun after each change.

If you are building a business site and do not yet have an agent, you can start free with Askocto, train it on your pages and use the script above. Other site builders follow the same pattern, so the steps for WordPress differ only in where the code goes.

Frequently asked questions

Can I add a chatbot to Wix without coding?

Yes. You paste one embed script into Wix's custom code setting. You do not write any code yourself.

Does adding a chatbot slow down my Wix site?

The script loads without blocking the page, so it should not hold up the content. Test your page speed before and after, and remove other widgets you no longer use.

Why can't I find the custom code option in Wix?

It depends on your plan and the current menu layout. Check your Wix plan and search the settings for custom code or tracking and tools.

Can I show the chatbot on only some pages?

Yes. Add the code to selected pages instead of the whole site, or control the widget with the open and close calls on specific pages.

Train an agent on your own help center

Askocto answers the repeat questions across chat, email and voice and hands the hard ones to your team.

Keep reading

All articles
Guideshow to build ai chatbot
Nov 21, 20255 min read

How to build an AI chatbot: a hands-on walkthrough

A hands-on walkthrough for building an AI chatbot: choose one job, load knowledge, write instructions, add one action, test with real questions and publish on one channel.

Read article