Squarespace

An AI chat widget for Squarespace, through Code Injection

An AI chat widget for Squarespace lets visitors to your portfolio, studio or small shop ask questions and leave their details, answered from the facts you paste and paid for with your own AI provider key. It installs through Code Injection, which Squarespace offers on Business plans or higher. This page covers the footer setup, the page-level choice and the editor caveat.

Business plan or higherfor Code Injection at the time of writing
Footer boxthe site-wide place for the script
Not a Code Blocka Code Block only affects its own page

Who benefits from chat on a Squarespace site

Squarespace is popular with creators, studios and small brands: design portfolios, photographers, fitness classes, newsletters, event pages. These sites are visual, with little text for anyone to search, so a visitor with a specific question about availability, pricing or fit has to email and wait.

  • Studios and freelancers: explain packages, lead times and what is not offered, then capture an enquiry.
  • Class and event pages: answer schedule, location and cancellation questions.
  • Small shops: cover shipping and returns; there is no native Squarespace commerce connector.

The enquiry path is the big one; read chatbots for lead generation and how to capture leads in chat.

Turn portfolio visits into enquiriesStart free, paste one snippet into Code Injection and test on your live site. No credit card.
Start free

Install on Squarespace in five steps

The Squarespace install guide has the complete walkthrough.

  1. Check your plan

    Code Injection needs a Business plan or higher at the time of writing. Without the option, upgrade first.

  2. Allow your origin

    Add your live address, such as https://www.example.com, to Allowed origins in SiteTrellis. Add the Squarespace-provided address if you will test there.

  3. Open Code Injection

    In Settings, Advanced, choose Code Injection and paste the snippet into the Footer box. The footer is where the script belongs.

  4. Save

    Click Save.

  5. Test on the live URL

    Open the live site in a private window, or while logged out, and hard-refresh.

Only on certain pages: two ways

Squarespace also supports per-page injection in the page’s Advanced settings, which suits a chat limited to a pricing or contact page. A more flexible route is to inject site-wide and use SiteTrellis page rules to include or exclude URL patterns, so you can change where the widget appears without editing Squarespace again. Do not use a Code Block for this: it affects only the page it sits on, so the widget would be missing everywhere else. See widget customization.

Editor, preview and trial-site caveats

  • Squarespace generally does not run injected code while you are logged in and editing, or in the editor preview. This is intentional; test on the live URL, logged out or in a private window.
  • Trial sites with a Squarespace-provided address have a different origin from your connected domain. Whichever origin you test from must be in the allowed list.
  • Versions 7.0 and 7.1 both have Code Injection, but the settings may sit in slightly different places.

If the launcher is still missing, check the Network tab for widget.js, confirm an agent is published and look for origin_not_allowed. Squarespace caches pages briefly, so wait a minute and hard-refresh. See troubleshooting.

What to paste as knowledge for a Squarespace site

  • Packages and what each includes, with price ranges and lead times.
  • Class or event schedules, locations, capacity and cancellation terms.
  • The process: how an enquiry becomes a booking, and what you need from the client.
  • Boundaries: what you do not do, so the agent can decline politely.
  • Digital download and refund terms if you sell them.

Squarespace member areas do not expose the visitor’s profile to page scripts in a standard way, so identifying members usually needs custom work. Instead, use the pre-chat form or let the agent ask for a name and email. See lead capture.

Honest limits on Squarespace

The widget does not read your Squarespace pages, sync products or take bookings from your scheduling tool. Replies arrive whole, and there is no voice or messaging channel. Compare routes on the Wix and any website pages, or see the integrations overview.

Frequently asked questions

Which Squarespace plan do I need for the chat widget?

Code Injection is available on Business plans or higher, and on the commerce plans, at the time of writing. Check Squarespace’s current plan details.

Where do I paste the SiteTrellis snippet in Squarespace?

In Settings, Advanced, Code Injection, in the Footer box. Then save and test on your live site.

Why do I not see the widget while editing?

Squarespace generally does not run injected code in the editor or editor preview. Open the live URL while logged out or in a private window.

Can I show the chat on one page only?

Yes. Use the page’s own Advanced header injection, or inject site-wide and use SiteTrellis page rules to include or exclude URLs.

Should I use a Code Block instead?

No. A Code Block only affects the page it is on, so the widget would be missing from the rest of the site.

Does it work on a Squarespace trial site?

It can, but the trial address is a different origin from your connected domain. Add whichever origin you test from to the allowed list.

Turn portfolio visits into enquiries

Start free, paste one snippet into Code Injection and test on your live site. No credit card.

  • No credit card
  • Live in about 5 minutes
  • Your keys, your rules
Start free, no credit card