Website
Add your AI to your website
Put a chat with your AI on your own site with one line of HTML. Visitors talk to it right there, in public mode.
Your website's visitors can chat with your AI without leaving your page. It takes two steps: the AI's owner allows your site, then you paste one line of HTML.
<script async src="https://app.uare.ai/embed/v1.js" data-handle="your-handle"></script>That line adds a chat bubble to the corner of every page it's on. Visitors open it and talk to your AI the way they would on your public profile.
1. Allow your website
Your AI only answers on websites listed in its owner's Settings on uare.ai. The AI's owner does this step, signed in to their account: if you're building the site for someone else, send them the addresses to add.
- Open Settings → Website in uare.ai.
- Add your site's address, for example
https://example.com. Addhttps://*.example.comas well to cover every subdomain, such aswww. - To try it on your computer first, add the local address you use, for example
http://localhost:3000.
Changes take effect within a minute.
2. Paste the snippet
The Website page shows your snippet with your handle filled in. Your handle is the last part of your public profile's address: for https://app.uare.ai/p/your-handle, it's your-handle. If your address ends in a long ID instead of a name, that ID is your handle.
Paste the snippet into your site's HTML, just before the closing </body> tag, on every page that should show the bubble. Most site builders have a place for it:
| Platform | Where the snippet goes |
|---|---|
| WordPress | The footer section of a header-and-footer code plugin |
| Webflow | Site settings → Custom code → Footer code |
| Shopify | Your theme's theme.liquid, just before </body> |
| Squarespace | Code injection, in the Footer box |
| Wix | Custom code, placed at the end of the body |
| Framer | Site settings → Custom code, at the end of the body |
| Next.js or React | See React and Next.js |
Open your site. The bubble appears in the bottom-right corner.
Put the chat inside your page instead
To show the conversation inside your layout instead of in a bubble, load the script once, then place a <uare-chat> element where it should go and give it a height:
<script async src="https://app.uare.ai/embed/v1.js"></script>
<uare-chat handle="your-handle" mode="inline" style="height: 600px"></uare-chat>Customize the widget covers colours, position, the greeting, and the JavaScript events your page can listen to. If your site builder only accepts an iframe, see Embed with an iframe.
What visitors get
- Public mode. Your AI answers from the knowledge you've made public and doesn't touch your private notes or connected apps, exactly as on your public profile.
- Free messages. Each conversation includes 10 messages. After that, the widget offers to continue on uare.ai, where visitors can sign up and keep talking to your AI.
- Memory across pages. The conversation follows visitors around your site. It ends after an hour without messages, or two hours after it started, and a new chat starts with a fresh allowance.
- No cookies. The widget stores the conversation in your site's browser storage and sends no cookies to uare.ai.
Troubleshooting
| What you see | What to do |
|---|---|
| No bubble, and the browser console says the site isn't on the list of allowed websites | The AI's owner adds the exact address from your browser's address bar in Settings → Website. https://example.com doesn't cover https://www.example.com: add both, or add https://*.example.com. |
| No bubble, and the console says no public AI answers to your handle | Check the handle against your public profile's address, and that your profile is public. |
| The console mentions a Content Security Policy | Your site restricts which scripts and servers its pages may use. Add https://app.uare.ai to script-src and connect-src. See Content Security Policy. |
| It works on your computer but not on your live site | Your live address isn't on the list yet: allowing localhost doesn't allow your domain. |
Next steps
- Customize the widget: attributes, colours, events and methods.
- Build your own chat UI: the same conversation through the public API, for a design that's entirely yours.