How to add a chatbot to any website with HTML

Start for free

About this integration

If you can edit your site's HTML, you can add the chatbot. The embed code is a single script tag that loads in the background and works with plain HTML, React, Vue, Next.js and any CMS. The chatbot answers from your own pages and documents.

What your agent can do

  • Answers from your content: only from the pages and documents you add, and says so when it doesn't know.
  • Speaks your visitors' language: it replies in the language the visitor writes in.
  • Captures leads: collects contact details with an AI summary (Pro and Business).
  • Books appointments: visitors pick an open time in the chat (Pro and Business).

How it works

  1. 1

    Create your AI agent

    Sign up to AgenBase, add your pages and documents, and test it in the builder.

  2. 2

    Copy the snippet

    On the agent's Install tab, copy the script tag.

  3. 3

    Paste it before </body>

    Add it just above the closing </body> tag, ideally in a shared layout or footer template so it's on every page.

  4. 4

    Single-page apps

    For React, Vue or Next.js, add it once to your root HTML template or root layout. The chat stays open while visitors move between pages.

  5. 5

    Deploy

    Publish or deploy your site as usual.

Check it works: Open your site in a new tab. The chat button appears in the bottom corner.

Explore other integrations. The same agent, the same knowledge, on whichever site you run.

WordPress

Build a custom AI chatbot for your WordPress website for free: train it on your pages and documents, then paste one line with a free footer plugin.

Shopify

Add a custom AI chatbot to your Shopify store without hiring a developer.

WooCommerce

Add an AI chatbot to your WooCommerce shop that answers customer questions from your shipping, returns and product pages.

Webflow

Add an AI agent to your Webflow site: paste one line into Footer code and publish.

Questions, answered.

Can't find your answer? The team replies within one business day.

What does the chatbot HTML code look like?

One script tag with your agent's public key, copied from the agent's Install tab. You don't write or style any HTML yourself: the script adds the chat button and window, in the colors you set.

Can I embed the chatbot inside a page instead of a bubble?

Yes. Besides the floating chat button, you can put the full chat inside a help or contact page with an iframe, or share a link to a hosted chat page.

I installed it but nothing appears

The chat bubble only shows while the agent is enabled. In AgenBase, open Agents, check the agent isn't disabled (Enable agent in its menu), then reload your site. Ad blockers can also hide chat widgets, so try a private window.

My site has a Content Security Policy

Allow the AgenBase app address in script-src and connect-src (and img-src if you use a profile picture), so the widget can load and send messages.

It shows on one domain but not another

If you set allowed domains on the agent's Install tab, the widget only loads on those domains and their subdomains. Add every domain your site uses, or leave the list empty.

Will it slow down my site?

No. The script loads in the background (async), so your page shows first and the chat button appears right after.

What does it cost?

AgenBase is free for 50 credits a month, with no credit card. Paid plans start at $35 a month for 1,000 shared credits and one included agent. Additional agents cost $20/month each on paid plans.

Put your knowledge to work.

Give visitors the answers they need and a clear next step. Build your agent, match your brand, and start turning conversations into leads and bookings.

Start for free