How to show tagged products first in a collection?

devautoshop
Visitor
1 0 0

I'm trying to figure out how to display products with a specific tag at the top of each collection page. Specifically, I want products tagged with "Hot" to appear first in every collection.

I've looked into the Shopify documentation and various forums, but I couldn't find a straightforward solution. Can anyone guide me on how to achieve this?

 

I know I can change it manually on each collection but I can't really do that because I have many "Hot" products and many collections.

Any code snippets, pointers, or suggestions would be greatly appreciated. Thank you!

Replies 2 (2)

gr_trading
Shopify Partner
1608 139 173

Hi @devautoshop,

 

You can put the loop code two times on the collection liquid file.

 

one will show the product has a valid tag on it and another will skip the product that has a tag on it, but this will impact the pagination of the collection.

 

there is no sorting available in Shopify for tags.

For any custom development WhatsApp or connect at Email ID: gr.trading15@gmail.com for quick consultation. | YouTube Videos
To support Buy Me a Coffee

Miriam_Solovey
Shopify Partner
32 0 2

Hi @devautoshop, this is Miriam from Kimonix app. You don’t have to work hard with implementing code for this - our app can help you with a click of a button 🙂

Simply use the push-up tags condition.
Here's how: Go to the sorting section called Tags and add the “Hot” tag to the push-up tags.

Here’s how it looks in the app:

Miriam_Solovey_0-1708870340328.png

 

You can also add several tags to be pushed up and the option to push down and exclude by tags.

I suggest watching this short video to see how easy it is to sort a collection using the app.

We are a plug-and-play solution (we are not touching your code) so feel free to try the app.

Hope this helps and let me know if you have any questions! 🤗