Use Shopify collections with Nyla
- Define the products, product order and page settings (handle, SEO) on product listing pages (PLPs)
- Define a list of products to be used on your site (e.g in cross sells, upsells or elsewhere)
- Use source collection properties to create dynamic experiences
This article covers:
- What aspects of collections are managed on Shopify, and what is managed on Nyla
- How to use Shopify collections with Nyla
- Setting up collections in Shopify for use on Nyla
- Using collections on your site
- How to hide and show products in collections on Nyla
- Changing the order of products in a collections
Managed on Nyla vs on Shopify
- On Shopify you manage:
- Your collections themselves, including what products are in the collection, and in what order they are in the collection
- The product status within the collections, including whether or not they are visible to Nyla or not
- On Nyla, you manage the pages your collections are featured on. Nyla pulls in collection data (source collection properties) that has been set in Shopify in order to use on these pages.
Using Shopify Collections with Nyla
In order to use collections with Nyla, you need to:
- Create the collection in Shopify
- Add the collection as a Source to your Nyla pages (either a page source, or a source: collection content item on a section)
To use Source Collections on Nyla, you should add either a collection either as a page source (if you are using the source collection on the entire page, like a PLP) or as a source collection content item within a section. You can then use collection properties
Creating collections in Shopify
Before doing anything in Nyla, you first need to create your collection in Shopify. See how to do that here. You should add SEO title and description to the collection in Shopify as well as the handle that you would want it to show up as on your site so that those details can be referenced in your page settings when you use your collection as a page source.
For collections to be available as a collection source in Nyla, they need to be available in the Nyla sales channel.
Using Collections in Nyla
- If creating a collection page (PLP), we suggest to set your collection source as a page source
- If using elsewhere (e.g in cross sells, etc) then you would just use the source collection content item
How to hide and show products in collections on Nyla
- Make sure the product is added to the collection in Shopify that corresponds with the collection source that is being used on the page
- Make sure the product is visible to Nyla
If the product is not showing up after those two steps, it could be that the automated publishing trigger from Shopify has failed, so you should refresh the data on that collection page or force a rebuild or the site.
- You can remove the product from the collection in question
- You can make the product invisible to Nyla by taking the steps listed here
- Remember to publish/rebuild the page(s) in question (or force a full site rebuild) after making the relevant changes on Shopify
- In same cases, you might want to exclude products from wherever they are showing up either in:
- The source collection content item using the Exclude feature (for example if you want to exclude page source products from a cross sell)
- For power users: the properties you are iterating over using array filters
Changing the order of items in a collection
Nyla pulls the products in the order in which they are set in Shopify. So, if you want to change the order of items in a collection, the best way is to re-order the products on Shopify itself and then publish your collection page(s) in question.
You could use array filters to sort the products by a given property.Troubleshooting a 404 page from a collection link
- Check to see whether the product should be visible in the collection in the first place. If not, then follow the instructions on how to hide or remove a product from a collection page on Nyla in order to make sure it no longer appears in the collection.
- Check to see whether or not the destination page in Nyla has been created. If it does not have a page, then create and publish one following the steps in this article.
- If there is an existing page in Nyla, you may need to publish your page
- If the page is published, then there may be an issue with the URL being linked to from the collection page. Check the URL of the page you expect to be linking to matches the link that was configured on your site