# Installing the widget on Shopify

> Add the chat widget to every page of your Shopify store by pasting the code into the theme's main file.

Page: https://supportfast.ai/en/guide/website/shopify/ · Section: Website · Updated on 30 October 2026

In Shopify, every page of the store is built from one theme file, `theme.liquid`. Paste the widget code there and the chat appears on the home page, collections, products and cart.

> **Before you start**
>
> - The widget code of an Active chat agent, copied from Chat agent › Agent profile › Share, Chat button panel.
> - Access to the Shopify admin with permission to edit the theme.

## Paste the code into the theme

1. **Open the themes**
   In the Shopify admin, go to Online Store › Themes (in an admin set to Italian, Negozio online › Temi).

2. **Open the code editor**
   Next to the published theme, press the three dots and choose Edit code (Modifica codice in Italian).

3. **Open theme.liquid**
   In the file search on the left, type `theme.liquid` and open the file. It's in the `layout` folder.

4. **Find where the header closes**
   Look for the `</head>` tag with `Ctrl` + `F` (on Mac `⌘` + `F`).

5. **Paste and save**
   Paste the widget code on the line right before `</head>`, then press Save (Salva in Italian).

> **Tip**
>
> **Duplicate the theme before editing it.** From the theme's three dots, choose Duplicate: if something goes wrong, you have a copy ready to publish.

> **Result**
>
> The widget appears on every page of the store that uses the theme.

## How to check

Open the store in a private window and follow the check in [Installing the widget](https://supportfast.ai/en/guide/website/install-widget.md#how-to-check), checking the home page, a product page and the cart. If the store is password protected, enter the password: the password page doesn't show the widget.

## Good to know

- **The code lives in the theme.** If you publish another theme, or install a new version of yours, check that the code is still there. If it's missing, paste it again.
- **No widget at checkout.** The payment pages aren't built from the theme file, so the chat doesn't appear there.
- **The .myshopify.com address.** If you fill in the [publishing domain](https://supportfast.ai/en/guide/website/install-widget.md#the-publishing-domain) with your own domain, the widget doesn't appear on the address ending in `.myshopify.com`.

## Removing the widget

Open `theme.liquid` again, delete the line with the code and press Save.

## Frequently asked questions

**The chat button covers the cart or another app's button. What do I do?**

Move it to the other side in Agent profile › Interface, with Button position.

**Can the chat recognize customers who have an account in the store?**

Yes, with a few lines in `theme.liquid`. The example is in [Passing user data](https://supportfast.ai/en/guide/developers/user-data.md#shopify).

## See also

- [Installing the widget](https://supportfast.ai/en/guide/website/install-widget.md): The code, the publishing domain and the check.

- [Passing user data](https://supportfast.ai/en/guide/developers/user-data.md): Registered customers' data, with the Shopify example.

- [Website widget](https://supportfast.ai/en/guide/help/widget-issues.md): What to do if the widget doesn't appear or covers other elements.
