How to Embed a Chatbot on HubSpot CMS (2026 Guide)

Step-by-step instructions to add a third-party chatbot to a HubSpot CMS website — site-wide header/footer HTML, per-page Advanced settings, Design Manager, and how to avoid conflicts with HubSpot's own chat widget.

What are the two ways to add a chatbot script on HubSpot CMS?

HubSpot CMS gives you two main places to inject third-party scripts: site-wide via the domain-level header/footer HTML fields in Settings, and per-page via the Advanced tab in the content editor. A third option — editing templates directly in the Design Manager — is available to developers on paid Content Hub plans and propagates the script to every page that uses a given template.

For most small businesses, the site-wide approach is the right choice: one paste, one save, and the chatbot loads on every page automatically. The per-page method makes sense when you want the widget on a specific landing page only — a quote request page, for example — and not on the rest of the site.

HubSpot CMS chatbot embed methods compared
MethodScopeWhere to find itBest for
Site Footer HTML (Settings)All pages on a domainSettings → Content → Pages → Site Footer HTMLMost businesses — one step, site-wide coverage
Per-page Footer HTMLOne page onlyContent editor → Settings tab → Advanced → Footer HTMLSingle landing pages or A/B test pages
Per-page Head HTMLOne page onlyContent editor → Settings tab → Advanced → Head HTMLScripts that must initialize before page content renders
Design Manager template editAll pages using that templateMarketing → Files → Design Manager → template fileDevelopers applying per-template logic on paid Content Hub plans

How do you add a chatbot site-wide via the HubSpot Pages settings?

The site-wide method uses HubSpot's Site Header HTML and Site Footer HTML fields — plain text areas inside your domain settings where any HTML or script tag you add loads on every page associated with that domain. Place your chatbot script in the Site Footer HTML field, not the header: floating widgets initialize correctly when the page body has already rendered.

  1. 1

    Open HubSpot Settings

    Click the gear icon in the top navigation bar of your HubSpot account to open the Settings panel.

  2. 2

    Navigate to Content → Pages

    In the left sidebar of Settings, click Content, then click Pages. This opens the Pages settings panel where domain-level defaults are configured.

  3. 3

    Choose your domain

    At the top of the Pages panel, use the "Choose a domain to edit its settings" dropdown. Select the specific domain where you want the chatbot to appear, or select "Default settings for all domains" to apply it across every connected domain in your account.

  4. 4

    Click Override default settings (if editing a specific domain)

    If you selected a specific domain, a button labeled "Override default settings" may appear in the Site Header HTML and Site Footer HTML sections. Click it to enable domain-specific code. If you selected "Default settings for all domains," this step is not required.

  5. 5

    Paste your chatbot script into Site Footer HTML

    Scroll to the Site Footer HTML section and paste your chatbot's <script> tag — for example: <script src="https://www.knobot.org/widget.js" data-key="YOUR_KEY" async></script>. Do not place it in Site Header HTML unless the vendor explicitly requires head placement.

  6. 6

    Click Save

    Click the Save button at the bottom of the panel. HubSpot propagates the change to all published pages on the selected domain. There is no additional publish step.

  7. 7

    Verify on the live site in a private browser window

    Open your live domain in an incognito or private browser window. The chatbot bubble should appear within a few seconds of the page loading. Do not test inside the HubSpot content editor — previews do not execute third-party scripts.

How do you embed a chatbot on a single HubSpot page only?

Per-page script injection is handled through the Advanced tab in HubSpot's content editor. This approach keeps the chatbot off the rest of your site — useful for a dedicated lead-capture landing page where you want to focus the visitor's attention without the widget appearing on the homepage or blog.

  1. 1

    Open the page in the content editor

    In your HubSpot account, navigate to Content → Website Pages (or Content → Landing Pages). Click Edit on the page you want to modify.

  2. 2

    Click the Settings tab

    Inside the content editor, click the Settings tab at the top of the editor panel. This shows the page's metadata and advanced configuration options.

  3. 3

    Select Advanced

    Within Settings, scroll to find and click Advanced to expand the advanced options section.

  4. 4

    Paste your script into the Footer HTML field

    Find the Footer HTML text area and paste your chatbot <script> tag. If the vendor requires head placement, use the Head HTML field instead. The Footer HTML field is not available for blog posts.

  5. 5

    Publish or update the page

    Click Publish (for new pages) or Update (for existing published pages) to apply the change. The script will load only on this specific page.

How do you embed Knobot specifically on a HubSpot CMS site?

Knobot generates a single async script tag from the dashboard. There is no HubSpot app to install, no OAuth flow, and no developer required. Knobot's Premium plan ($79/month) includes 10,000 messages per month — enough for most small business sites without per-conversation overage charges. A 14-day trial with 100 free preview messages lets you verify the integration before committing.

  1. 1

    Create a Knobot account and set up your business profile

    Sign up at knobot.org. During onboarding, enter your business URL — Knobot uses retrieval-augmented generation (RAG) to scrape your site and build the initial knowledge base automatically. You do not need to write FAQ responses by hand.

  2. 2

    Customize the widget in the Knobot dashboard

    Set the primary color, welcome message, and lead-capture fields (name, email, phone) to match your brand. You can also configure which information the widget collects before handing off to your inbox or webhook.

  3. 3

    Copy the embed snippet from Embed → Get Code

    In the dashboard, navigate to Embed → Get Code. Copy the full script tag. It looks like: <script src="https://www.knobot.org/widget.js" data-key="YOUR_KEY" async></script>. Your unique data-key ties the widget to your business's knowledge base and settings.

  4. 4

    Paste into HubSpot Site Footer HTML

    Follow the site-wide steps above: Settings → Content → Pages → choose your domain → Site Footer HTML. Paste the snippet and click Save.

  5. 5

    Add your domain in Widget → Install

    Back in the Knobot dashboard, navigate to Widget → Install and add your exact live domain — both the apex domain (yourbusiness.com) and the www version (www.yourbusiness.com). Knobot authorizes the widget to initialize only on domains you have explicitly registered.

  6. 6

    Send a test message

    Open your live HubSpot site in a private browser window, trigger the chatbot, and submit a test lead. Confirm the lead appears in the Knobot dashboard under Conversations and that any configured webhook or email notification fires.

How do you prevent your chatbot from conflicting with HubSpot's own chat widget?

If HubSpot's native chat feature (sometimes called HubChat) is enabled on your site, both widgets will try to appear in the bottom-right corner of the page. The result is one widget stacking on top of the other, making both unusable. This is the most common embedding issue on HubSpot CMS sites.

There are two clean ways to resolve it:

Running two chat widgets simultaneously on the same page is not recommended even without visual overlap — it creates a confusing experience for visitors who have to choose between them. Pick one and disable the other on pages where they would both appear.

What should you do if the chatbot does not appear after saving?

If the Site Footer HTML is saved correctly but the widget does not appear on your live site, work through these causes in order.

How does HubSpot's HTTPS requirement affect chatbot scripts?

HubSpot enforces HTTPS across all CMS-hosted pages. This means any external script your chatbot loads — the widget JavaScript file, API calls, and any CDN assets — must also be served over HTTPS. Browsers block mixed-content requests: an HTTPS page cannot load resources over plain HTTP. Any chatbot vendor that still serves its widget script over HTTP will be silently blocked on HubSpot pages — this is a browser enforcement, not a HubSpot restriction.

HubSpot does not apply a custom Content Security Policy (CSP) by default on standard CMS-hosted sites, so a script tag added through Site Footer HTML runs without additional configuration. The exception is if your organization has configured a custom CSP through a CDN or proxy layer in front of HubSpot — in that case, you would need to add the chatbot vendor's domain to the script-src directive of your policy. This is rare for small businesses using standard HubSpot CMS hosting.

Can you add a chatbot via the HubSpot Design Manager?

Yes, for developers with Design Manager access. The Design Manager lets you edit the raw HTML of HubSpot templates — the files that control the layout of pages built on that template. Adding your chatbot script to the footer of a template file propagates it to every page using that template, which gives you more granular control than the site-wide Site Footer HTML field (you can apply the chatbot to some templates but not others).

This approach requires a paid Content Hub plan and familiarity with HubSpot's HubL templating language. For most small businesses, the Settings → Content → Pages → Site Footer HTML path is faster, does not require developer access, and achieves the same result for the common case of embedding a chatbot site-wide.

Frequently asked questions

Do I need a paid HubSpot plan to add a custom chatbot script?

The site-wide Site Header HTML and Site Footer HTML fields are available across HubSpot Content Hub plans, but capabilities vary by tier. The Design Manager (for template-level edits) and advanced developer features require a paid Content Hub plan. If you are on CMS Hub Free or a very limited plan, use the per-page Advanced → Head HTML or Footer HTML field instead — that is generally accessible across more plan types. When in doubt, check your account's feature access under Settings → Account Defaults.

Will my chatbot conflict with HubSpot's own live chat widget?

Yes, if HubSpot's native chat (HubChat) is active on the same pages, both widgets will try to render in the bottom-right corner and overlap each other. The fix is to disable HubSpot chat on those pages — go to the HubSpot chat widget settings and use page-targeting rules to exclude the pages where your third-party chatbot runs. Alternatively, configure your third-party chatbot to appear in a different corner (bottom-left, for example) via dashboard settings.

Can I embed a chatbot on a single HubSpot landing page rather than site-wide?

Yes. Open the page in the content editor, click the Settings tab at the top, then select Advanced. Paste your chatbot script into the Footer HTML field. The script will load only on that specific page. This approach works on both website pages and landing pages in HubSpot.

Does HubSpot's CDN or CSP block third-party chatbot scripts?

HubSpot enforces HTTPS on all hosted pages, so your chatbot vendor must serve its widget script over HTTPS — otherwise the browser blocks it as mixed content. HubSpot does not apply a restrictive Content Security Policy by default on standard CMS-hosted sites, so pasting a script tag into the Site Footer HTML or Footer HTML field will run without additional configuration. If you use a custom server proxy or non-standard CDN setup, verify your server's CSP headers allow the chatbot vendor's domain.

Can I add a chatbot to HubSpot pages built with a custom template in the Design Manager?

Yes. In the Design Manager, open the template file you want to edit and add the chatbot script tag directly to the template's HTML — typically in the footer section, above the closing </body> tag. Changes to a template propagate to all pages that use it. This method requires developer access (Design Manager access) and a paid Content Hub plan. For non-developers, the site-wide Site Footer HTML approach is simpler and achieves the same result.

What happens if I set Site Header HTML at the domain level vs the default level?

HubSpot lets you configure site-wide code at two scopes: "Default settings for all domains" (applies across all connected domains) and a per-domain override. If you add a chatbot script at the default level, it runs on every domain connected to your HubSpot account. To limit it to one domain, select that domain in the "Choose a domain to edit its settings" dropdown and click "Override default settings" — then paste your script there. Code in a domain-specific override replaces the default for that domain; it does not stack on top of it.

Does Knobot require any server-side configuration on HubSpot?

No. Knobot is a client-side widget — one async script tag is all that is needed. There is no server plugin, npm package, or API credential to configure inside HubSpot. The only server-side step is adding your live domain to the Knobot dashboard under Widget → Install so the widget is authorized to load on that origin.

Sources