Embed the chatbot on your website
You add one single line of code in one place — and the chatbot then appears automatically on every page of your website. You do not have to edit every page individually.
The code
Copy your personal widget code from the dashboard. It looks like this, with your own slug instead of YOUR-SLUG:
<script src="https://websitechatbot.ch/widget.js" data-slug="IHR-SLUG" async></script>Name, colour and avatar are configured in the dashboard under Settings → Appearance. You don't need to adjust the code for that.
Guides by website builder
Click on your website builder — the detailed step-by-step guide will expand. If your provider isn't listed, just write to us: info@websitechatbot.ch.
Static HTML site or hand-coded site
- If you use a shared footer include (e.g.
footer.html, a PHPinclude, or a template in Hugo/Jekyll/Eleventy): paste the widget code there once, directly before</body>. That's enough for the entire site. - If every page is its own HTML file and there's no shared template: the code really does have to be added before
</body>in every file. Use VS Code or Sublime Text, open all files, and use Find & Replace across files: search for</body>, replace with your widget code followed by</body>. Done in 10 seconds.
WordPress
- Open your browser and type into the address bar:
your-website.com/wp-admin(replace your-website.com with your own address). Log in with your WordPress username and password. - In the left vertical menu: hover over Plugins and click Add New.
- In the top-right search box, type
WPCode. The first result is called WPCode — Insert Headers and Footers + Custom Code Snippets. Click the blue Install Now button next to it and wait a few seconds until it changes to Activate — click that too. - A new entry called Code Snippets now appears in the left menu. Hover over it and click Header & Footer.
- You see three large text boxes: Header, Body, Footer. Click into the Footer box and paste your widget code (Ctrl/Cmd + V).
- Click the blue Save Changes button at the top right.
- Done. Open your website in a new tab and press Ctrl + Shift + R (Windows) or Cmd + Shift + R (Mac) for a full reload. The chat button appears in the bottom right.
Wix
yourname.com — not yourname.wixsite.com). It does not work on the free plan.- Go to wix.com and log in.
- You'll see your site(s) listed — click Select & Edit Site (or Manage Site) on the relevant one.
- In the left menu of the dashboard: Settings — usually near the bottom.
- Scroll to the section Development & integrations and click Custom Code.
- Click the + Add Custom Code button at the top right.
- Paste your widget code into the large text field Paste the code snippet here.
- Set the following options: Add Code to Pages = All pages and Load code once. Place Code in = Body – end.
- Click Apply at the bottom right. Open your website in a new tab and do a full reload — the chat button appears.
Squarespace
- Log in at squarespace.com.
- Click on the website you want to edit to open its overview.
- In the left menu: Settings.
- Click Advanced, then Code Injection.
- Paste your widget code into the Footer field. Not "Header" or "Lock Page".
- Click Save at the top left. Open your website in a new tab and do a full reload (Ctrl/Cmd + Shift + R).
Jimdo
- Log in at jimdo.com and open your website.
- Click Edit at the top right to enter edit mode.
- Open the menu at the top left (three lines / hamburger icon) and select Settings → Edit Head.
- Paste your widget code into the text field and click Save.
- Even though the code is in the Head section, the widget loads asynchronously and still appears in the bottom right on every page. Reload your website to test.
Shopify
- Log in to your Shopify admin (
yourshop.myshopify.com/admin). - In the left menu: Online Store → Themes.
- On your current theme (at the top of the list), click the three-dot button ⋯ next to Customize, and choose Edit code.
- On the left you'll see a file tree. Open the Layout folder and click the file theme.liquid.
- Press Ctrl/Cmd + F to open a search, and look for
</body>. Place the cursor on the empty line directly above it and paste your widget code. - Click Save at the top right. Open your shop in a new tab and reload it — the chat button appears in the bottom right.
Webflow
.webflow.io URL without a plan, the code won't load. If you use Webflow for free, you'll need to activate a Site Plan first (starting around USD 14/month).- Open your project in the Webflow Designer. At the top left next to the Webflow logo: click the gear icon for Site Settings.
- Click the Custom Code tab.
- Scroll to the Footer Code section (before the closing body tag) and paste your widget code there.
- Click Save Changes.
- Back in the Designer: top right, click Publish → Publish to Selected Domains. Important: the code only goes live after publishing — preview alone is not enough.
IONOS MyWebsite
- Log in at ionos.com (or your country's IONOS site) and open the MyWebsite editor.
- In the left menu: Settings.
- Click Custom Head Code.
- Paste your widget code into the text field and click Save.
- Click Publish at the top right so the change goes live.
STRATO Homepage Builder
- Log in to your STRATO customer area and click Edit website.
- In the editor: Content Elements → Standard Elements. Look for the element Embed.
- Drag the Embed element with your mouse into your footer area (or another area that's visible on every page of your site).
- Once the Embed element is placed, you'll see a small gear icon at the top right of the element. Click it.
- In the popup: paste your widget code into the Embed Code field and click Save.
- Click Publish at the top right of the editor. Open your website in a new tab and do a full reload — the chat button appears.
Hostpoint Sites
- Log in to the Hostpoint Control Panel and open your Sites website in edit mode.
- Click in your footer area (the bottom area that appears on every page) on + Add Element.
- Select the element Embed (or HTML embed).
- Paste your widget code into the text field and click Apply or Save.
- Click Publish at the top. Reload your website — the chat button appears in the bottom right.
Localsearch (MyWEBSITE)
- Open the Localsearch support form.
- Ask support to add the widget code to your site's footer, or directly before the closing
</body>tag — that way the chatbot appears on every page. Just use the template below. YOUR-SLUGis your personal identifier. Here's how to find it: log in to your dashboard and look at your browser's address bar — your identifier is the part after/dashboard/. Example: inwebsitechatbot.ch/en/dashboard/mycompany-ch, the identifier ismycompany-ch. ReplaceYOUR-SLUGin the template with exactly that value.- Once Localsearch confirms it's live, the chat button appears in the bottom right. Reload your site once (Ctrl + Shift + R).
Template to copy:
Hello,
I'm a MyWEBSITE customer and I'd like to add a small tool (a chatbot) to my website.
Could you please insert the following line of code into my site's footer, or directly before the closing </body> tag, so that it's present on every page:
<script src="https://websitechatbot.ch/widget.js" data-slug="YOUR-SLUG" async></script>
Please publish the site afterwards and let me know once it's online.
Thank you and best regardsGoogle Sites
Verify
- Open your website in a new tab and do a full reload: Ctrl + Shift + R (Windows) or Cmd + Shift + R (Mac). This bypasses the browser cache.
- A round chat button should appear in the bottom right within 1–2 seconds.
- Click it → the chat window opens. Ask a question about your business (e.g. about your opening hours) to confirm the answers match your website.
If nothing appears
- Open the browser console (right-click on the page → Inspect → Console tab). If you see an error with
data-slug attribute is required, the slug is missing or misspelled. - Did you actually save the code? Many CMSs require an extra click on "Publish" — saving alone is often not enough. In Webflow, for example, you have to click Publish to Selected Domains.
- Content Security Policy: if your site has a strict CSP (very rare on SMB sites), allow
script-src https://websitechatbot.chandconnect-src https://websitechatbot.ch. - Widget hidden by other content: very rare. Send us an email and we'll solve it together.
Help with installation
Got a different website builder or the installation isn't working? Just reply to your welcome email or write to info@websitechatbot.ch — we'll help personally with the installation, free of charge.