# Add a survey to Shopify store pages

Add a feedback button or put a survey inside a store page. First [install and open Shopoll](/installation.md) and publish a survey. Then follow these steps in Shopify’s theme editor.

## Turn on the feedback button

1. In Shopify admin, open **Online Store → Themes** and edit the theme you want to use.
2. Open **App embeds** and turn on **Shopoll feedback**.
3. Choose which survey to show, as explained below.
4. Under **Show survey**, choose **Feedback button**.
5. Save the theme. Open a page in its preview and click the feedback button to test it.

If you switch themes, turn on **Shopoll feedback** in the new theme too. This setting adds the button to store pages. Checkout pages need a [separate survey block](/installation/activating-shopoll-on-shopify-checkout-extensions.md).

## Choose which survey appears

To show **one survey**, paste its **Published survey ID** into the block or app embed.

To let **Shopoll choose a survey**, leave the ID blank. In Shopoll, turn on **Include in automatic website selection** for each survey you want to use, then save and publish. Shopoll checks your [live survey list](/accounts/live-surveys.md) and shows the first survey that matches the visitor and page.

## Show a survey on particular store pages

In a new survey, choose **Website** and pick **Product pages**, **Collection pages**, **Cart page** or **Homepage**. Shopoll uses the page type supplied by your Shopify theme. A product reached through a collection is still a product page. On websites using standard Shopify-style addresses, Shopoll can also recognise those pages from the path.

To change a saved rule, open **Settings → Audience and placements**, choose **Website visitor** and edit the **Store page type** rule. You can select more than one type. Save and publish your changes.

## Include and exclude pages

In a new survey, choose **Website → Custom page rules**. For an existing survey, open **Settings → Audience and placements → Website visitor → Page locations**.

For example, to ask about product descriptions but skip clearance items, add two rules:

| Show or skip | Comparison | Path or address |
| --- | --- | --- |
| Include | Starts with | `/products/` |
| Exclude | Contains | `clearance` |

One matching inclusion is enough. An exclusion always wins. If you add only exclusions, the survey can appear on any other page that meets your audience settings. Use **Try a page address** to check a page you want to include and one you want to skip. This checks page locations only. Use **Preview who qualifies** to test visitor conditions such as language or device.

Choose **Matches exactly** for a single page or **Ends with** for pages sharing the same ending. Capitalisation is ignored. Exact matches accept a trailing slash. Enter a path to use the rule across stores. A full address limits the rule to that exact hostname. With **Starts with**, a domain-specific rule also recognises the path inside a longer address. For example, `shop.example/products/` includes `shop.example/collections/sale/products/notebook`.

Turn on **Match the query string** to distinguish addresses such as `/offers?campaign=spring` and `/offers?campaign=autumn`. Use public campaign values in your rules. The visitor’s browser checks the query. Save the draft and publish to apply the rules.

## Choose when the survey opens

Choose **Use survey trigger settings** in the app embed. In Shopoll, edit the survey and expand **Website triggers, frequency and exit behaviour**. Choose an appearance pattern and publish the survey.

- **Feedback button** shows the launcher immediately. The survey opens when the shopper clicks it.
- **Ask on arrival** opens the survey automatically on an eligible page, without a launcher. If the survey was centred, this preset moves it to the bottom right; otherwise it keeps its position.
- **Ask in a modal** opens the survey automatically in the centre, without a launcher.
- **Ask after engaging** shows a launcher immediately and also opens the survey automatically at 50% scroll depth. Clicking the launcher opens it sooner.
- **Exit intent** has no launcher and starts watching for signs of leaving after 20 seconds. The timer itself does not open the survey.
- **Open from code** hides the launcher and waits for your website to call `Shopoll.open()`.
- **Custom** lets you time the launcher and survey separately. The delay begins once the shopper reaches the chosen scroll depth. Choose whether it resets on each page or continues across the visit. Each timing rule can apply to desktop, mobile or all screen sizes.

A preset can change the launcher and position for this survey. You can try the result in its storefront preview before publishing.

### Set launcher and survey timing separately

Choose **Custom**, then use **Open the survey** to choose **When a shopper clicks**, **Automatically**, **From code** or **On exit intent**.

**Launcher timing** controls when the feedback button becomes available. **Survey timing** controls automatic opening, or when exit detection starts. For example, show the launcher immediately and open the survey automatically after 20 seconds. If the shopper opens it first, the pending automatic opening is cancelled.

For either timing rule, the delay starts after the chosen scroll depth is reached. **On this page** restarts the timing on a new page load; **Across this site visit** keeps the deadline across page loads on the same site. Device restrictions apply separately to each rule.

With **When a shopper clicks**, selecting **No launcher** leaves no built-in button: open the survey from your own code or choose another opening mode. With **Automatically** or **On exit intent**, the survey can open without a launcher. **From code** never shows the built-in launcher.

**Survey position** under **On-site → Layout** controls where the opened survey appears. **Launcher side** controls the button's left or right placement. Neither setting chooses when the survey opens. See [design defaults](/accounts/design-defaults.md).

## Override the trigger in the theme

Under **Show survey**, you can choose:

- **Custom JavaScript trigger** to open it from [your own button](/tutorials/custom-trigger.md).
- **After a delay** to open it after a set number of seconds.
- **After scrolling halfway** to open it when someone scrolls halfway down the page.
- **Exit intent** to open it when someone appears to be leaving.

To limit the button to part of your store, enter a page prefix in **Path starts with**. For example, `/products/` limits it to product pages.

## Put a survey inside a page

1. Open the page template in Shopify’s theme editor.
2. In a section that allows app blocks, choose **Add block → Apps → Shopoll survey**.
3. Enter a **Published survey ID**, or leave it blank to let Shopoll choose.
4. Save. The survey appears in the section you chose.

To place several surveys in existing theme sections with the same workspace script, set a container CSS selector in each survey. [Embed a survey in a page](/embed.md)

## Check who can see it

Automatic surveys may wait for Shopify’s analytics consent. See [consent settings](/cookie-consent.md) to use your own cookie banner or apply the same check to a survey chosen by ID.

Survey rules can limit who sees it by page, language, device or traffic source. Dates, response limits, how often it may appear and a visitor’s earlier dismissal can also stop it opening.

Test a page that matches your rules and one that does not. Then submit an answer and check **Results** in Shopoll. You can also [check the latest recorded visit](/installation/check-installation-status.md).

To reach shoppers who have added items, set a [cart condition](/polls/targeting-settings/cart-conditions.md) on the survey’s website audience.
