Deploy to your website

Add the chat to your custom website

Add the Assistrio AI chat widget to a coded website — HTML, React / Vite, Next.js, Vue, or Angular — by hand or with a ready AI prompt.

Your website is your own code — not a website builder like Shopify or Wix? The Chat Widget is one short snippet: a <link> and two <script> tags. It goes once in the file every page shares, just before </body>.

Before you start

  1. 1

    Open Deploy

    In Assistrio, open your agent and click Deploy in the top bar. Pick Chat Widget.

  2. 2

    Add your website

    Under Allowed websites, add your site's address. The chat only loads on websites you add here, and Copy code stays off until you add one. Just the domain is enough — https:// and www are covered for you. See Allowed websites.

  3. 3

    Copy the code

    Click Copy code in the steps. It's the normal Chat Widget code — there's no app or plugin of ours to install.

Deploy

Deploy on

Chat WidgetEmbed a floating Chat Widget on any website.
IframeEmbed the agent as an inline element on any website.

Website builders

Shopify
WooCommerce
WordPress
Wix
Webflow
Squarespace
Framer
BigCommerce
More platforms in the user guide

Other channels

Center StageA large chat in the middle of your website, with its own install code.
Help pageA full-page chat with its own link.
SlackYour team asks the agent in Slack.
EmailYour agent answers customer emails.
Deploy in the top bar: your platform is under Website builders, other channels below.

Where the code goes

How your site is builtWhere to paste the codeGuide
HTML / static site (PHP, Jekyll, Hugo, Django, Rails…)The shared footer or base template, just before </body>.HTML & static sites
React / Vite (Lovable, Bolt, Create React App)index.html — not inside a React component, so it loads once.React & Vite
Next.js (v0)The root layout: app/layout.tsx (or pages/_document.tsx), with next/script.Next.js
Vue / Nuxtindex.html, or app.head in nuxt.config.ts.Vue & Nuxt
Angularsrc/index.html, after <app-root>.Angular
SvelteKit, Astro, Remix, GatsbyThe app shell or base layout.All frameworks
index.htmlHTMLOnce, before </body>
1 <body>
2 <!-- your page -->
3 <link rel="stylesheet" href="…/assistrio-chat.css" />
4 <script>window.AssistrioChatConfig = { agentId: "…" };</script>
5 <script src="…/assistrio-chat.js" async></script>
6 </body>
7</html>
On any site, the code goes once, just before </body>, in the template every page shares.

Let your code editor do it

Using Cursor, Claude Code, GitHub Copilot, or another AI coding tool? Pick it and how your site is built — React / Vite, Next.js, plain HTML, and more — then copy the prompt and paste it into the tool. In Assistrio, Deploy › Chat Widget › Install with AI gives the same picker with your code already in it. Built with Lovable, Bolt, or v0? See Claude, Lovable, Bolt & v0.

AI tool you use

How your site is built

Add the "Assistrio" AI Chat Widget to my website.

What to do:
- Find the file that every page shares (for example index.html, app/layout.tsx, a base template or the site footer) and add the code there once, just before </body>.
- Tell me which file you changed.
- Add it only once. Don't add it twice or load it again on each page change.
- Paste the code exactly as it is. Don't change the agentId or the URLs.

How to check it works:
- Open the website: a Chat Widget shows at the bottom right.
- Send it a message like "Hi": the agent answers.
- If it doesn't show, check the code is on the page and look for an [Assistrio Chat] message in the browser console.

The code:
[Paste your install code from Assistrio › Deploy › Chat Widget › Copy Snippet here]

Replace the last line with your install code from Deploy › Chat Widget › Copy Snippet. In Assistrio, Install with AI fills it in for you.

Check it works

  • Open your site in a private (incognito) window, so you see what visitors see: the chat button shows at the bottom right of every page.
  • Click it and send “Hi” — your agent answers. Chats you start here show in Activity › Chat logs.
  • Change the look or welcome message any time in the Playground — no need to paste the code again.
yourwebsite.com
ACMEProductPricingHelp
NovaWe reply in a few minutes

Hi! 👋 How can I help you today?

Type a message…
The result: the Chat Widget at the bottom right, open on top of your page.

Not showing?

  • Built with React, Vue, or another single-page app? Make sure the code is in index.html (or the root layout), not in a component that mounts on each page change.
  • Site behind a CDN or page cache? Clear it after you deploy.
  • Check the address under Allowed websites is the one in your browser's address bar. A different subdomain (like shop.example.com) needs its own entry. Each agent can have up to 3.
  • Check the Chat Widget's Visibility is on (top of Deploy › Chat Widget).
  • Two chat buttons? The code is on the page twice (for example in the theme and in a plugin) — remove one.
  • Still nothing? Open the browser console (right-click › Inspect › Console) and look for an [Assistrio Chat] message: it says what's missing. More fixes in the FAQ.

Update or remove it

  • Changes in Assistrio (look, knowledge, actions, welcome message) show on your site by themselves. You don't paste the code again.
  • Paste it again only if you Rotate the secret key (the Shopify, WordPress, and WooCommerce codes are signed with it), or if you move the code to a new theme or template.
  • To remove it, delete the code from your template or layout and save (and publish). To hide it without touching your site, turn off Visibility at the top of Deploy › Chat Widget — as long as another channel is on, since at least one channel must stay on.

Center Stage

Want Center Stage — the “Ask AI” box at the bottom center — instead, or as well? Pick Center Stage in the Playground, open Deploy, and pick Website under Center Stage. The steps are the same with its code. If the Chat Widget code is already there, keep it and paste Center Stage's next to it.

Next steps

Was this page helpful?

Need help? Contact support — we reply within one to two business days.