> ## Documentation Index
> Fetch the complete documentation index at: https://guide.beenos-solutions.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Embed the Beenos Solutions Chat Widget on Any Site

> Add a fully branded AI chat widget to your website in minutes using a single script tag. Customize colors, position, and welcome messages.

The Beenos Solutions chat widget lets you surface any of your deployed AI agents directly on a website without building a custom UI. A single script tag is all you need to get a fully functional, branded chat experience live on any page — from a marketing site to a product documentation portal. You can customize the widget's appearance and behavior entirely through HTML data attributes.

## Embedding the widget

<Steps>
  <Step title="Open your agent's Deploy tab">
    Navigate to the **Agents** page in your workspace, click the agent you want to embed, and then click the **Deploy** tab.
  </Step>

  <Step title="Copy the widget script snippet">
    Under the **Chat Widget** section, click **Copy Snippet**. The snippet includes your unique agent ID and a set of default configuration attributes already filled in.
  </Step>

  <Step title="Paste the script into your page">
    Open your website's HTML and paste the script tag just before the closing `</body>` tag. This placement ensures the widget loads after the rest of your page content.
  </Step>

  <Step title="Reload your page">
    Save your changes and reload the page in a browser. The chat widget appears in the bottom-right corner by default and is immediately ready to use.
  </Step>
</Steps>

Here is what the full script snippet looks like:

```html theme={null}
<script
  src="https://cdn.beenossolutions.com/widget.js"
  data-agent-id="YOUR_AGENT_ID"
  data-primary-color="#ef7025"
  data-position="bottom-right"
  data-welcome-message="Hi! How can I help you today?"
  async
></script>
```

Replace `YOUR_AGENT_ID` with the agent ID shown in your Deploy tab. All other attributes are optional and can be removed to use the default values.

## Configuration options

Customize the widget's look and behavior by adding or modifying data attributes on the script tag.

| Attribute              | Required | Default                         | Description                                                                                                   |
| ---------------------- | -------- | ------------------------------- | ------------------------------------------------------------------------------------------------------------- |
| `data-agent-id`        | ✅ Yes    | —                               | The unique ID of the agent to power the widget. Found in the Deploy tab.                                      |
| `data-primary-color`   | No       | `#ef7025`                       | Hex color code used for the widget launcher button and chat header.                                           |
| `data-position`        | No       | `bottom-right`                  | Position of the widget on screen. Accepts `bottom-right` or `bottom-left`.                                    |
| `data-welcome-message` | No       | `Hi! How can I help you today?` | The opening message shown to visitors when the widget first opens.                                            |
| `data-open-on-load`    | No       | `false`                         | Set to `true` to automatically open the chat panel when the page loads.                                       |
| `data-hide-branding`   | No       | `false`                         | Set to `true` to remove the "Powered by Beenos Solutions" footer. Available on Pro and Enterprise plans only. |

## Restricting domains

By default, the widget script can be embedded on any website. To prevent unauthorized sites from using your agent, you can configure an **allowed domains** list.

Navigate to your agent's **Deploy** tab, scroll to the **Domain Restrictions** section, and add the domains you want to permit (for example, `yourcompany.com` or `docs.yourcompany.com`). Once you save the list, the widget will only initialize on pages served from those domains. Requests from any unlisted origin are silently blocked.

This is especially important if your agent has access to sensitive or proprietary knowledge base content that you do not want publicly accessible through an unauthorized embed.

<Tip>
  The `data-hide-branding` attribute is available on **Pro and Enterprise plans**. Removing the "Powered by Beenos Solutions" label is a great way to deliver a seamless, fully white-labeled experience for your users. Upgrade your plan under **Settings → Billing** to unlock this option.
</Tip>
