How can I filter by product color in version 2.0 without using variants?

Hello!

how can I define the Color of a simple product in 2.0? In the old version it was possible to do this by using a tag (depending on the theme). Now it is only possible to filter the colors of my products with color variants. For example: black dress simple product, T-Shirt blue and red variant: the filter will only show blue and red, because the black dress has no variant. But I want my customers to be able to filter by the Color of every product and not just the products with variants. I tried to define the color in the metafields, but I don’t know if I have done this correctly- there is no color swatch in my filter sidebar. If I can’t define the color metafield for this, I don’t know how I can use it correctly. Does anybody have an idea how I can solve my „simple-product-color-filtering-problem“ without using a third party app?
thank you!
vicky

3 Likes

Same problem I am facing and thought there will be an easy answer on the community forum. :disappointed_face:

I think this could be easily solved by Shopify. The Color could be treated like a simple product information. Similar to price information. And with an general switch whether you want to display the color swatch for simple products (without variants) on your productsite or not. But I could be totally wrong, and this is too hard to code ?‍ :female_sign:

1 Like

Hello! I just had a long support chat with Shopify, and I am very proud, that the support and I found a solution together. I wanted to share with you what we found out, since you are facing the same problem.

You can select only one color per product. But the support told me, he found out, that many Shopify users have this problem since 2.0 and if its possible, Shopify will be updated to fix this problem completely. After the update you can choose more than one color for your product. But at the moment you can only define one color. I hope this is helpful for you, it worked for me. My Shopify is in german, and i am german, so please excuse me, if my english is not perfect :slightly_smiling_face: I do my best for you :wink:

try this:

  1. Set up you color swatches by uploading th colors as a .png them into your files. be sure to name your pngs correctly as you need them. you will need the name of the png later to display the color correctly in your filter.
  2. Set up metafield: create a new single-line text metafield for products. Don’t use the color picker, use text. this is important!

you can add additional rules to define your color names already in metafields. Type in all the color names separately (one line for each color) this will see you time, when you define the colors in your products.

  1. go to your navigation. in 2.0 you will find a new field named “Filters” underneath the menus.

Add a filter. Now you can add the metafield in your filter. Select the one you just created.

  1. go to the products where you want to add the color. scroll down. you will find the metafield you just created. find the right color in the dropdown list you just created. save product.

Now open your shop. Your filters should show the color swatches and you should be able to filter by color, as easy as it was by tags. :slightly_smiling_face:

let me know if this is understandable for you and if this worked for you.

vicky

7 Likes

Vicky, you are an angel :slightly_smiling_face:

I followed your instructions and it actually works !! have a look at this collection page of my website! WOW!

https://genejack.com/collections/bags

I will even start adding more metafields for styles, fitting..etc

Thank you so much, you made my day :slightly_smiling_face:

Kind regards

Yas

2 Likes

I have seen your website. Wonderful to see color swatches.

I tried to implement the same. But I am not getting png images on filter view.

Please help me.

Thanks

I tried to implement the same. But I am not the getting png images on filter view.

Please help me.

Thanks

Let’s take example of color ‘red’

Step1: Create a file for red color swatch, file name Red, file format png, file size 32 x32 px

Step2: Settings > Files: upload the file

Step3: Settings > Metafields > Products > Add Definition

Name: Color > Select content type Text > Single Line text > Save

Step4: Products > Select any of your products > scroll all the way down you will find a new section called Metafields and a new line called Color > enter the name Red

Step5: Sales Channel > Navigation > You will see Filters Section > Add Filter > Add Color Metafield

Step6: Go to your website and check the filter :slightly_smiling_face: if it works then repeat step the steps for all the colors you wish

Kudos to @vaubeo for finding this out

1 Like

Thank you so much for your immediate response. Hats off.

Did as per your steps:
Geting color name but not PNG.

https://chettinad-thari.myshopify.com/collections/chettinad-cotton-sarees

Please help me.

I think your theme might need an additional step for complex colors :s

To narrow down the issue, why dont you try first straightforward color such as ‘Blue’? if this works then probably complex swatches could be looked at separately

For standard colors I didnt face any issues, for complex colors I had to define one more step on my theme (sorry I missed this in my previous reply)

Let us know if standard colors will show correctly to you

I attach some ready swatches if that could help

1 Like

Thank you so much. Now it is working fine.

One more request.

Is it any way to remove colour name like this https://genejack.com/collections/bags

Thanks

Thank you so much. Now it is working fine.

One more request.

Is it any way to remove colour name like this https://genejack.com/collections/bags

Thanks

Hello @vaubeo ,

Can you please clarify the second step?

"2) Set up metafield: create a new single-line text metafield for products. Don’t use the color picker, use text. this is important!

you can add additional rules to define your color names already in metafields. Type in all the color names separately (one line for each color) this will see you time, when you define the colors in your products."

Where should I type all the color names?

Thank you

I have found it,

When you are creating the metafield, after selecting the “Text” option, in the “Validation” tab, and checking the box “Limit to preset choices”, becomes available the option to add more items. - problem solved here.

But the colors are not showing up, only the names. I have tried these options “examplecolorname.png” and the link itself that directs to the import file, none of them worked.

Any hint?

Thank you

Hi,

When you create the options in the metafield you should not name it „color.png“. Just „color“.

The .png is only important for your Color files (means the color swatches) which you have to import to your files. It is important to have your swatches as a .png and not as a .jpg

i hope this helps

vicky

If I understand your questions correctly you wanted a color filter that filters products with multiple selection capability. If the default theme filter cant handle it, I would recommend using an app like https://apps.shopify.com/ultimate-search-and-filter-1. You can easily add a Color filter using tags by selecting Tag from the filter type in the Edit Filter form then enable the Multi-selection mode. You can also use product options as colors and the app will show the correct variant image when user selects a color.

Hi, you might have an answer to this one as well.

What if I’m selling a t-shirt which is made of two colors. Is it possible to show the product when selecting e.g. Red, but also when selecting Blue? (when it’s a blue/red shirt)

Cheers,

Hey, this is something we tried to achieve and for long time we kept researching , unfortunately we do not see this as a standard option at all and can not be achieved without a 3rd party app. There a couple of decent applications who can do this by grouping different products as variants i.e. you create a blue tshirt and red tshirt as separate products then use the app to combine them as variants. This way you have 2 products displayed and both display the color variants without messing up with you SKU count

Hope this helps

@Genejack9to5

Hello! I implemented the metafeilds and added the current values to my produces but I still can’t get the actual color swatches to show… all it shows is the actual color name… no image/swatch. I also notice you have some theme setting called “Color Swatch”. I do not have this I am using the Ira theme.

Is a specific theme required for this to work? I noticed Mahalakshmi got this to work as well, but I’m not sure how… Any help would be greatly appreciated.

1 Like

Hi there

I tried all the step but the colour swatches still isn’t showing up on the collection page, just coming up with words. Does this work only for certain themes. I have Ira 4.0 theme