Conditionally Hide the Gift Message Option on Product Pages 🏷️

Update 2021: Showing the gift message options on a per product basis is now best handled entirely by the product options feature. The default gift message feature can then be disabled.

In order to hide the default Gift Message option conditionally on your product pages based on individual products or collections, you can detect the contents in different manners (properties, tags, collections, etc.), and then conditionally load some CSS on your store if certain conditions are met.

Choose how you would like to build in this logic, and then find your product.liquid or product-template.liquid theme file.

Here is an example that shows how to only show the Gift Message option on two specific collections:

{% if template contains 'product' %}
	{% if product.title == "Product Name X" or product.title == "Product Name Y" %}
        <style>
        #gsAppContainer {
            display: none !important;
            }
 		 </style> 
    {% endif %}
{% endif %}

Can't find the answer in our documentation?
Contact Support