Shopify themes, liquid, logos, and UX
Hello guyz,
Please, I need help with the advanced meta objects for the product category list so that a new filter appears with new types of clothing.
In the Shopify control panel the path is: Settings ↳ Custom Data ↳ Products ↳ (tab) Assigned to Category ↳ Clothing Features (meta object) ↳ Category Assignment in the three dots, then the following tree appears:
The final result should be a new category:
Final result on the store should be a new filter:
First, the metaobject or clothing feature you're assigning needs to be linked to the product correctly. It looks like you’re already doing that under “custom data → assigned to category” which is perfect. Just double check that the product itself is actually saved with that assigned clothing feature.
Next, in your Shopify theme customizer under Search & Discovery, you’ll want to go into the filters section and make sure that “Clothing Features” or the name of the metaobject you’re using is added as a filter. That’s what tells your store to pull it in and show it on the storefront.
Once that’s added and a few products are assigned those new values, Shopify should automatically show those options in your filter sidebar like “Chalecos,” “Parkas,” or whatever else you include.
If this fixed your issue, likes and accepting as a solution are highly appreciated
| Build an online presence with our custom-built Shopify Theme: EcomifyTheme
| Check out our reviews: Trustpilot Reviews
| We are Shopify Partners: EcomGraduates Shopify Partner
Hi @Dropex
I am from Mageplaza - Shopify solution expert.
You're diving into a powerful feature — Shopify Metaobjects — to build custom filters (like new clothing types) on your product category (collection) pages. I'll walk you through this step by step, using Metaobjects to extend product data and show it as a custom filter in your store’s collection filters.
Add "Clothing Type" as a new custom filter using Metaobjects, and make it appear on the collection (category) page.
Step 1: Create a Metaobject Definition
1. Go to your Shopify Admin.
2. Navigate to: Settings > Custom data > Metaobjects
3. Click “Add definition”.
4. Name it something like: Clothing Type.
5. Under Fields, click “Add field”, and configure:
6. Enable “Storefronts” and “Custom storefronts” visibility.
7. Save.
Step 2: Add Metaobject Entries (Clothing Types)
1. After saving, go to: Content > Metaobjects > Clothing Type
2. Click “Add entry”.
3. Add different types of clothing:
You now have a database of clothing types as Metaobjects.
Step 3: Link Metaobject to Products
You’ll now link a metaobject field to products so you can tag each product with a clothing type.
1. Go to Settings > Custom data > Products.
2. Click “Add definition” (or edit an existing one).
3. Add a new field:
4. Save.
5. Now, go to any Product, scroll to Custom data, and you’ll see “Clothing Type”.
6. Select the correct clothing type for that product.
Step 4: Show Clothing Type in Collection Filters
This requires modifying your theme’s filtering system. There are two approaches:
Option A: Use Shopify Search & Discovery App (Easier but Limited)
If you're using Shopify's Search & Discovery app:
If Metaobjects don’t show here, you’ll need to use Option B.
Option B: Manual Code for Advanced Custom Filtering
This is if you want full control or the metafield is not filterable in Search & Discovery.
{% assign all_types = '' %}
{% for product in collection.products %}
{% if product.metafields.custom.clothing_type %}
{% assign clothing_type = product.metafields.custom.clothing_type.name %}
{% unless all_types contains clothing_type %}
{% assign all_types = all_types | append: clothing_type | append: ',' %}
{% endunless %}
{% endif %}
{% endfor %}
{% assign clothing_type_array = all_types | split: ',' | uniq %}
<div class="custom-filter">
<label for="clothing-type">Clothing Type:</label>
<select id="clothing-type" onchange="handleTypeChange(this)">
<option value="">All</option>
{% for type in clothing_type_array %}
{% if type != '' %}
<option value="{{ type | downcase }}">{{ type }}</option>
{% endif %}
{% endfor %}
</select>
</div>
<script>
function handleTypeChange(select) {
const selected = select.value;
const url = new URL(window.location.href);
url.searchParams.set("clothing_type", selected);
window.location.href = url.toString();
}
</script>
4. On page load or in JS, you can filter collection.products based on the URL param clothing_type.
Please let me know if it works as expected!
Best regards!
Mageplaza | Top-Rated Shopify Agency | Trusted by 230,000+ worldwide merchants
If our suggestion works for you, please give it a Like or mark it as a Solution!
Should you have any questions or concerns, feel free to contact us via consultant@mageplaza.com
Discover how to increase customer engagement on your store with articles from Shopify A...
By Jacqui Apr 23, 2025Hey Community 👋 Did you know that March 15th is National Everything You Think Is W...
By JasonH Apr 1, 2025Discover how to increase the efficiency of commerce operations with Shopify Academy's l...
By Jacqui Mar 26, 2025