Widgets let you add an Autohive AI agent to your website as an embedded chat widget. Website visitors can ask questions, upload files if enabled, send screenshots if enabled, and continue a conversation without needing an Autohive account.

Each widget belongs to a workspace, is connected to one agent, and only works on the website domains you allow.

Widgets page showing existing widgets and their actions

Before you start

Make sure you have:

  • An Autohive workspace with Widgets enabled
  • A workspace agent that is ready to answer website visitors
  • Access to edit your website HTML or a CMS custom-code area
  • The website domain where the widget should appear

For best results, configure the agent’s instructions, knowledge, and integrations before connecting it to a widget. See Agent settings for more detail.


Open Widgets

  1. Open the workspace that should own the widget.
  2. Click Widgets in the workspace header.
  3. Click Create Widget.

If the workspace does not show a Widgets tab, the feature may not be enabled for that workspace or plan.


Create a widget

When creating a widget, the form starts with three sections: General, Appearance, and Behavior. After the widget is created, Autohive shows the Installation section with the embed code. Existing widgets also show Installation while editing.

General

Create widget form showing widget name, agent, and allowed domains

Use General to choose the agent and control where the widget is allowed to run.

FieldDescription
Widget NameInternal name shown in Autohive. Visitors do not see this name.
AgentThe Autohive agent that answers visitor messages.
Allowed DomainsWebsite domains where the widget is allowed to start sessions and receive visitor messages.

The installation script URL is public, but Autohive checks allowed domains before the widget can start a visitor session or send messages. Add each domain or subdomain that should use the widget.

Examples:

  example.com
www.example.com
help.example.com
  

Do not include paths like /pricing or /contact. If you need to test on a local website, add localhost as an allowed domain.

Appearance

Widget appearance settings and preview

Use Appearance to control how the widget looks on your site.

SettingDescription
Display NameName visitors see in the chat widget header.
Welcome MessageFirst message shown when the widget opens.
PositionPlaces the launcher at the bottom-right or bottom-left of the page.
Primary ColorMain widget colour, used for the launcher and primary UI.
Text ColorText colour used on primary-colour areas.
Border RadiusControls how rounded the widget UI appears.

Use the preview panel while editing to check the widget style before saving.

Behavior

Widget behavior settings for screenshots, attachments, and rate limits

Use Behavior to control screenshots and uploads.

SettingDescription
Enable ScreenshotsLets visitors capture and attach a screenshot to a message.
Enable File AttachmentsLets visitors upload files into the conversation.
Max file sizeSets the maximum upload size. Choose 1, 2, 3, 5, 10, 15, or 20 MB.
Max uploadsSets the maximum number of uploads per conversation. Choose 5, 10, 15, 20, 25, or 50 uploads.
Allowed file typesLimits attachments to selected extensions.

Supported attachment types are:

  pdf, doc, docx, xls, xlsx, txt, csv, png, jpg, jpeg, gif, webp
  

Install the widget

Widget installation section with embed code

After you create the widget, Autohive shows the installation code.

  1. Copy the code snippet.
  2. Paste it into your website HTML just before the closing </body> tag.
  3. Publish or deploy your website.
  4. Open the website and confirm the widget launcher appears.

The snippet looks like this:

  <script src="https://app.autohive.com/widget/v1/{public-widget-id}/embed.js" async></script>
  

If your site uses a CMS like WordPress, Webflow, Squarespace, or Shopify, look for a Custom Code, Header/Footer Scripts, or Theme code area and place the snippet near the end of the page body.

Identify visitors

Use Identify visitors in the Installation section when your website can provide the visitor’s name or email address.

When enabled, Autohive includes an extra configuration block before the script:

  <script>
  window.AutohiveWidgetConfig = {
    user: {
      name: '',  // Visitor's display name
      email: ''  // Visitor's email address
    }
  };
</script>
<script src="https://app.autohive.com/widget/v1/{public-widget-id}/embed.js" async></script>
  

Replace the empty values with data from your website, app, or CMS. Leave the setting off if your site does not know who the visitor is.


Test the widget

Live widget preview on a website page

Test the widget before sending real visitors to it.

  1. Use Preview from the widget form or the widget row options menu.
  2. Open the real website page where you installed the script.
  3. Click the widget launcher.
  4. Send a test message and confirm the agent responds.
  5. If screenshots or attachments are enabled, test an upload that matches your configured limits.
  6. Test the widget from each allowed domain or subdomain.

Changes to appearance and behavior are served from Autohive. You normally do not need to reinstall the script after editing the same widget. If a change does not appear immediately, wait about a minute and refresh the page.


Manage widgets

The Widgets page lists every widget in the workspace. Use the search field to filter by widget name or agent.

Each widget row shows:

ColumnDescription
Widget nameInternal widget name.
AgentAgent connected to the widget.
SitesAllowed domains for the widget.
Date createdDate the widget was created.
ActionsActive toggle and options menu.

Widget actions

Use the three-dot menu on a widget to:

  • Preview — open a live preview of the widget
  • Copy embed code — copy the installation snippet again
  • Edit — update the agent, allowed domains, appearance, behavior, or installation options
  • Delete — remove the widget from the list

Use the active toggle to turn a widget on or off without deleting it. Disabled widgets stop loading on external sites, and active visitors see that the chat is no longer available.

Deleting a widget removes it from the list. Any installed script for that widget becomes inactive.


Visitor experience

Visitors see a launcher button on your website. When they open it, the widget starts or resumes their conversation with the selected agent.

The widget:

  • Runs inside an isolated widget container so site styles do not interfere with chat styles
  • Stores the visitor session in the browser so conversations can continue across page loads
  • Uses the selected agent’s name, instructions, and capabilities available in the widget
  • Supports screenshots and file attachments only when enabled for the widget
  • Does not require visitors to sign in to Autohive

If a visitor clears browser storage, uses another browser, or switches devices, Autohive treats them as a new visitor.


Common issues

ProblemWhy it happensHow to fix
Widget does not appear on the websiteThe domain is not allowed, the widget is inactive, or the script was not added to the pageCheck the active toggle, confirm the script is present, and add the exact domain or subdomain to Allowed Domains
Widget works in Preview but not on the websitePreview runs from Autohive, while your website must pass the allowed-domain checkAdd the website domain, such as example.com or www.example.com, then refresh the site
Widget does not load on local developmentlocalhost is not automatically allowedAdd localhost to Allowed Domains while testing locally
New colours or settings do not show immediatelyThe embed script may be cached brieflyWait about a minute, then refresh the page
Visitors cannot upload a fileAttachments are off, the file type is not selected, or the file exceeds the size/count limitTurn on Enable File Attachments and check the file settings
Screenshot capture is missingScreenshot support is offTurn on Enable Screenshots in Behavior
Widget creation failsA required field is missing, the name already exists, or no valid agent is selectedChoose an agent, use a unique widget name, and correct any highlighted fields

Best practices

  • Give the widget a clear internal name, such as Marketing Site Support or Help Centre Assistant.
  • Use one widget per website experience when domains, styling, or agent behavior should differ.
  • Add both root and www domains when visitors may use both.
  • Keep the welcome message short and specific.
  • Enable file uploads only when the agent needs files to answer well.
  • Test the widget after changing the connected agent’s instructions or integrations.