Exclude Product From Search Shopify

Exclude Product From Search Shopify

Rate this article

Share this article

Read eCommerce search for more information.

In the dynamic world of e-commerce, managing your Shopify store effectively is crucial for providing a seamless shopping experience to your customers. One essential aspect that often requires attention is the optimization of your search functionality. In this guide, we’ll delve deeper into the process of excluding specific products from search results on Shopify, ensuring that your customers find exactly what they’re looking for.

Understanding the Need:

While Shopify offers robust search capabilities, there are instances where you might want to exclude certain products from search results. This could be due to various reasons, such as seasonal items, out-of-stock products, or exclusive promotions. By refining your search results, you can enhance user experience and guide your customers towards the most relevant and available products.

Step-by-Step Guide:

Accessing your Shopify Admin:

To begin, log in to your Shopify admin dashboard. Navigate to the “Products” section, where you can manage your product listings.

Product Tagging:

One effective method to exclude products from search is by using product tags. Assign a specific tag to the products you wish to exclude. For instance, you could create a tag named “ExcludeFromSearch.”

Modify Liquid Code:

Shopify’s Liquid code allows you to customize various aspects of your store. In this case, you’ll need to modify the search.liquid template. Locate the code that generates search results and add a condition to exclude products with the designated tag.
Copy code
{% for item in search.results %}

{% unless item.product.tags contains ‘ExcludeFromSearch’ %}

<!– Display the product –>

{% endunless %}

{% endfor %}

Regularly Review and Update:

E-commerce stores are dynamic, with product availability changing regularly. It’s essential to review and update your excluded product list consistently. Remove the exclusion tag from products that are back in stock or no longer part of an exclusive promotion.

Useful Apps:

Shopify’s App Store offers various apps designed to enhance the platform’s functionality. Explore apps that provide advanced search customization options, allowing you to exclude products based on specific criteria without manual code modifications.

Best Practices:

Transparency with Customers:

If certain products are intentionally excluded from search results, consider communicating this information to your customers. Implement a clear messaging system on your website or within the product pages to inform users about the exclusions and guide them to relevant alternatives.

Regular Testing:

After implementing changes, perform thorough testing to ensure that the search functionality operates as intended. Check various scenarios to guarantee that excluded products are appropriately filtered from search results.

Exclude Product From Search Shopify

If you want to hide a product and prevent people from finding it on your Shopify store, there are a few steps you need to take.

Obviously, you can just set the product as a Draft, which only allows your Staff to view it, but maybe you want to hide a product from your storefront but still allow users to access it via a direct link.

Exclude Product From Search Shopify

Get the ExpertRec Shopify App

This could be because you’ve got a special offer product, one which you only want to promote to specific customers via an email mailshot or AdWords campaign, or perhaps something isn’t quite ready and you want to share with a member of your team via a secret link, without giving them access to your store’s back end.

It’s easy enough to hide products on Shopify – you just don’t add them to a collection and ensure that you have set up a manual ‘All’ collection that excludes the product.

However, the one place that the product will continue to show up is in your site’s search area. If your product has a similar name to another one of your products, someone may accidentally stumble across it when searching for a similarly-named product.

Thankfully, it’s pretty easy to hide a product from your shop’s search. It involves adding some custom metadata.

This is the data you want to add:

"namespace" : "seo"
"key" : "hidden"
"value" : 1
"value_type" : "integer"


Optimizing your Shopify store’s search functionality by excluding specific products is a strategic move to enhance user experience and guide customers towards the most relevant offerings. Whether using product tags or exploring specialized apps, taking the time to refine your search results will contribute to a more efficient and user-friendly online shopping environment.

Remember to stay proactive in reviewing and updating your exclusion criteria to align with the evolving nature of your e-commerce business. By implementing these strategies, you’re not only improving the functionality of your Shopify store but also elevating the overall satisfaction of your customers.

Add great search to your Shopify site at 9 USD per month

Are you showing the right products, to the right shoppers, at the right time? Contact us to know more.
You may also like