Skip to main content
Bubble takes the SmartAlex widget as one script tag, with no Bubble plugin. Paste it into the app-wide header to show it on every page, or into an HTML element on one page. Visitors can then talk or type to your agent.
In the app: Agent Settings → Widget → Install → Install code. In Bubble: Settings → SEO / metatags → Script/meta tags in header.
The diagram shows how the widget loads.

How do I get my snippet?

1

Copy the Install code

In SmartAlex open Agent Settings → Widget → Install → Install code and press Copy. Your data-tenant-id is filled in. A connected AI app can fetch it too.
2

Turn the widget on

Switch on Show widget on my website in the same place.
The tag is the same for every widget style:

How do I add it to every page?

1

Open app settings

In the Bubble editor go to Settings, then the SEO / metatags tab.
2

Paste into the header field

Find Script/meta tags in header and paste the tag. It is added to every page of your app.
3

Deploy

Click Deploy to push to live, then open your live address.
Script tags in the header field need a paid Bubble plan, so on the free tier use the HTML element below.

How do I add it to one page?

1

Drag in an HTML element

From Visual elements, drag an HTML element onto the page. A small hidden one is fine, because the widget floats over the page.
2

Paste the tag

Double-click the element and paste the tag into its content.
3

Preview

Click Preview. The widget is fixed to the browser window, not to the element.
Keep the HTML element out of repeating groups and reusable elements that render many times, so the widget loads once.

Which widget style should I pick?

You choose the style in Agent Settings → Widget, not in Bubble. Widget v2 gives voice and chat in one window. Pill, Chat bar, Side panel and Voice pill are the others, and only one widget is active per workspace. See Widgets.

What should I watch for in Bubble?

  • Preview and live: the widget works in both once the tag is there. Preview runs the development version and Deploy publishes.
  • One copy only: do not paste the tag in both the header and an HTML element on one page.
  • Consent banners: if a script blocker is in use, allow api.getsmartalex.com.
  • Allowed websites: if you set that list in Agent Settings → Widget, add your Bubble domain. See Installing the widget.
When the agent needs to act on your own systems during a call, such as looking up a booking, add Custom HTTP Tools. They need the Power Tools add-on (add-ons and prices).

Questions people ask

The app-wide header field needs a paid Bubble plan, so on the free tier use an HTML element, which works on any plan.
The tag is loaded twice. Do not paste it in both the header and an HTML element on one page, and keep it out of repeating groups.
No. The widget floats above the page in a fixed position, so Bubble layouts and breakpoints do not move it and you need not reserve space.

Installing the widget

The full install guide and fixes.

Widgets

The five styles, colours and limits.

Next.js and Vercel

The widget in a React front end.

Build overview

Guides for every builder.
Last modified on November 27, 2026