<defaltam/>

Platforms

How to add an AI chatbot to a plain HTML website

For static HTML sites, adding an AI chatbot is one script tag before </head> on every page. Steps, includes, and how to avoid missing pages.

In short

On a plain HTML site you add an AI chatbot by pasting one script tag before the closing </head> tag of every page you want it on.

If your pages share a header include or template, add it once there instead of editing every file.

4.7·130 reviews

Key facts

Key facts

The snippet

<!doctype html>
<html>
  <head>
    <meta charset="utf-8" />
    <title>Your site</title>
    <script src="https://defaltam.com/api/public/bot/widget?k=YOUR_PUBLIC_KEY" async></script>
  </head>
  <body>...</body>
</html>

Avoid the half-installed site

The common mistake on static sites is adding the script to index.html and forgetting the other twenty pages, so the bot vanishes exactly where visitors have questions. If you build with includes, a static site generator or a template, put the line in the shared head partial once.

Indexing a static site

Static sites index cleanly because everything is plain HTML text. Make sure your prices and policies are in the markup rather than inside images, and the bot will answer them accurately.

The product behind this guide

A chatbot trained on your own website, live today

Defaltam builds AI chatbots that read your public pages and answer with your real prices, services and policies. Support is €79/month, Sales is €149/month, both start with a 5-day free trial, and installation is one script tag.

FAQ

Questions people ask about this

How do I add a chatbot to a static HTML website?

Paste the chatbot script tag inside the <head> element, before the closing </head>, on every page. If your pages share a header include or template, add it there once.

Does it work on GitHub Pages or Netlify?

Yes. The widget is a hosted script, so any static host serves it without extra configuration.

Do I need a build step?

No. It is a single HTML line with no dependencies.

Can I put it before </body> instead?

It will still work, but <head> is recommended so the widget is ready as soon as the page is interactive.

Related

Keep reading.