Widget targeting works only with App Theme blocks and Shopify 2.0 themes

Widgets normally added to the store by Widget ID, but in some cases you’d like to show different widgets on same page types. For example:

  • Different product reviews on Product page
  • Display widget only on specific Product page
  • Different widgets on Collection page

Create widget with targeting

On widget page find section “Targeting” with different target options:

  • Disabled
  • Product - show on product pages
  • Collection - show on collection pages
  • URL - show on specific URL

Product

If you’d like to show widget on Product page, select “Product” in targeting list and choose product.

Collection

If you’d like to show widget on Collection page, select “Collection” in targeting list and choose product.

URL

Paste URL where widgets should be visible. For example, https://store.com/products/dress. URL matching is strict.

Don’t forget to Save changes!

Prioritization

When we are searching widget to show, we looking in this priority:

  1. Widget ID
  2. Product or Collection
  3. URL

Adding App block to the theme

Assuming you have added widget for product page, we can add App Block to product page.

Open Theme Editor inside Shopify.

On top bar select template for “Product”.

On left sidebar click on “Add Section” and on tab “Apps” find “Storista Widget” and add new block.

On block settings where is option to add “Widget ID”, because with targeting we don’t know which widget to show, “Widget ID” field should be empty.

Click on “Save” to save changes.

That’s it. Now open URL https://yourdomain.com/products/dress to see result. Open different product and confirm that widget not visible.

Limitations

Where are few limitations on using targeting feature:

  1. Products are visible only in preview mode, small cards in carousel not visible
  2. Multiple widgets with targeting on same page not supported. Hovewer, you can add second widget without targeting
  3. Multiple widgets with same targeting not suported. If you can’t find widget with same targeting, contact support.

Adding multiple widgets on same page

If you need to add multiple widgets on same page, where is one simple rule: Only one widget should be with targeting, other widgets should use “Widget ID” field.