Merchant Center / Google Shopping Ads - How to deal with missing attribute: color if each color variation is created as a separate product?

zin
Shopify Partner
32 0 0

Hi,

I created the product feed for google merchant with the google shopping app… The remarketing feed looks somehow ok but there's an issue with the google shopping ads feed.

The diagnostic tells me that the color attribute is missing:

I want to set up the shopping ads campaign for a small fashion brand selling apparel. As the number of styles is relatively small, we didn't use color as a product variant, such as size. Instead, each color of a style is represented as a separate product. The only attribute/variant we populate is size. That seems to be the reason why the attribute color is not uploaded to google merchant.

Any advice, how I can upload the color automatically via the app without having to change the product structure within Shopify.

Thanks

Zin

 

0 Likes
Victor_B
Tourist
12 0 1

Hi !

 

Personally i had to add a color to all of my products while it would have been much better for me to add gemstones / materials types ... Color is a bit useless but if Google wants the color, i add the color.
I contacted Shopify support but it seems there is no workaround for that. Maybe you can try to reach Google...
If you find a solution feel free to share !

good luck

http://shapeyourtime.com
0 Likes
Kevin6
Shopify Partner
12 0 4

Hi,

This is a common problem when trying to list on Google Shopping, especially since Shopify only allows 3 custom fields per product.

We offer a service that lets you add custom attributes to products to meet the requirements of the Google feed spec.

Let me know if you need help getting started.

Best,

Kevin

0 Likes

Zin, DataFeedWatch is a good solution for feed management. I use it for nearly 10 clients now. You can do something more manually with a Google Spreadsheet if you have few products.

Run Google Shopping ads? Get the free definitive guide to Google Shopping for Shopify (no optin required): https://www.digitaldarts.com.au/google-shopping
0 Likes
zin
Shopify Partner
32 0 0

Here's how the issue was solved:

  1. create a variant attribute color and fill it in with values -> upload to google merchant works
  2. hide the color selection in the theme as there's only one value. see how this was done here
0 Likes
preston1
Shopify Partner
1 0 0

If you're using the debut theme like I am the #2 of zin's solution didn't work (I was able to fill in the color variants fine and the google merchant feed worked, but then I users were seeing a color option on each product even though there was only one color for each item).

Here's how I fixed it:

1) Open Sections -> product-template.liquid
2) Around line 143 for me (differ depending on customizations you've made) you'll see:

          <form action="/cart/add" method="post" enctype="multipart/form-data" class="product-form product-form-{{ section.id }}{% unless section.settings.show_variant_labels %} product-form--hide-variant-labels{% endunless %}" data-section="{{ section.id }}">
            {% unless product.options.size == 1 and product.variants[0].title == 'Default Title' %}
              {% for option in product.options_with_values %}
                <div class="selector-wrapper js product-form__item">
                  <label {% if option.name == 'Color' %}style="display:none" {% endif %}for="SingleOptionSelector-{{ forloop.index0 }}">
                    {{ option.name }}
                  </label>
                  <select class="single-option-selector single-option-selector-{{ section.id }} product-form__input" id="SingleOptionSelector-{{ forloop.index0 }}" data-index="option{{ forloop.index }}">
                    {% for value in option.values %}
                      <option value="{{ value | escape }}">{{ value }}</option>
                    {% endfor %}
                  </select>
                </div>
              {% endfor %}
            {% endunless %}

3) Adding this in 3 places will hide all "color" options from your theme: {% if option.name == 'Color' %}style="display:none" {% endif %}

Here is the code with this added in all the necessary places:

          <form action="/cart/add" method="post" enctype="multipart/form-data" class="product-form product-form-{{ section.id }}{% unless section.settings.show_variant_labels %} product-form--hide-variant-labels{% endunless %}" data-section="{{ section.id }}">
            {% unless product.options.size == 1 and product.variants[0].title == 'Default Title' %}
              {% for option in product.options_with_values %}
                <div class="selector-wrapper js product-form__item" {% if option.name == 'Color' %}style="display:none" {% endif %}>
                  <label {% if option.name == 'Color' %}style="display:none" {% endif %}for="SingleOptionSelector-{{ forloop.index0 }}">
                    {{ option.name }}
                  </label>
                  <select {% if option.name == 'Color' %}style="display:none" {% endif %}class="single-option-selector single-option-selector-{{ section.id }} product-form__input" id="SingleOptionSelector-{{ forloop.index0 }}" data-index="option{{ forloop.index }}">
                    {% for value in option.values %}
                      <option value="{{ value | escape }}"{% if option.selected_value == value %} selected="selected"{% endif %}>{{ value }}</option>
                    {% endfor %}
                  </select>
                </div>
              {% endfor %}
            {% endunless %}

I'm sure this isn't the best solution since it relies on you explicitly declaring the variant option you want to hide but it's a fast solution to a problem that I'm sure a lot of people have since Google requires color attributes in a lot of categories including fashion, accessories, shoes, jewelry, etc.

You can see this in action on our site: https://ikiki.co/products/dr-owlivia-hoot

And you can verify via the inspector that the data is there, just hidden:

 

0 Likes