Two products share the same GTIN
A GTIN names one item worldwide. When two products share one, a shopping service may limit them or merge both into a single listing.
The symptom
A product you never touched disappears from a shopping service, or two different items in your store end up sharing a single listing with the wrong photo. In the admin everything looks right: both products exist, both have an identifier, and WooCommerce raised no objection when they were saved—because they were not saved through the product screen.
What it costs
An identifier exists to name exactly one trade item anywhere in the world. When two of your products carry the same one:
- Google limits them. Merchant Center’s rules say not to submit several products with the same GTIN, condition, and pack size for one country and language, and a product that breaks its GTIN rules may get limited visibility.
- Two products become one listing. A comparison site can merge them, so a customer clicking your cheaper item lands on the other one’s page.
- Stock and returns go to the wrong row. Anything that matches orders back to products by identifier picks whichever it finds first.
If a shopping feed is what brought you here, this is one of several requirements that drop products without saying so. Why products drop out of your shopping feed walks the rest the same way, with the query for each.
How to check it yourself
From WP-CLI, without any plugin:
wp db query "SELECT TRIM(meta_value) AS gtin, COUNT(*) AS n \
FROM wp_postmeta pm JOIN wp_posts p ON p.ID = pm.post_id \
WHERE pm.meta_key = '_global_unique_id' AND TRIM(pm.meta_value) <> '' \
AND p.post_type IN ('product','product_variation') \
AND p.post_status IN ('publish','draft','private') \
GROUP BY TRIM(meta_value) HAVING n > 1"
Replace wp_ with your table prefix. Empty values are excluded on purpose—twenty products with no
identifier are not twenty duplicates of each other.
From an export, with nothing to install. Open the CSV product export in the GTIN validator: it lists the codes that repeat, with row numbers and product names—including ones written differently, with a leading zero or an invisible character. The file never leaves your browser.
How to fix it
- Find out which product the number actually belongs to—the packaging decides, not the order history.
- Clear the field on the other one and enter its own number. Leave it empty rather than guess.
- If both are variations of the same product, check whether one is a leftover from a deleted attribute value; those are usually better removed than renumbered.
- Fix the import that produced it. A duplicate identifier almost always comes from a spreadsheet column copied down a row too far, and it comes back with the next import.
When it’s a false alarm
- Translations of one product. With WPML or Polylang, one item lives in several posts that legitimately share an identifier. Merchlint counts a translation group as one product; if your multilingual setup is different, hide the finding.
- Multipacks priced per unit. Some stores list the same item in several pack sizes. Strictly each pack size needs its own GTIN, but until you have them, this is a known state rather than a mistake.
- One item sold new and used. A used item keeps the manufacturer’s number. Google tells you to
submit that GTIN with the condition set to
used, and its GTIN help page shows one book listed new and used with the same ISBN. WooCommerce has no condition field, so Merchlint can’t see the difference: hide the finding. Your feed has to send the condition, because a used item that goes out as new is a duplicate.
If WooCommerce refuses the second product. WooCommerce has no setting for this, but one line of
code switches its duplicate check off. Add it with a code snippets plugin or in your child theme’s
functions.php:
add_filter( 'wc_product_pre_has_global_unique_id', '__return_true' );
The line applies to the whole store, so a number typed twice by mistake is no longer refused. We tested it on WooCommerce 11.2.1 on November 3, 2026.
Correction, November 4, 2026: we previously wrote on this page that a duplicate is never deliberate, and we left condition and pack size out of Google’s rule.
How Merchlint finds it
Merchlint reads _global_unique_id from published products and from their variations, groups by
value, ignores empty ones, and reports each product that shares its number with
another product, with a variation of a different product, or with its own variation. The set is
computed once for the entire store, not per batch—a duplicate whose twin sits in another part of
the catalog is still a duplicate. Variations sitting in the trash never count.
Numbers are compared the way a person reads them. From version 0.3.5 an invisible character or a non-breaking space—common when a number is pasted from a spreadsheet—does not make a different number, and spaces at either end are ignored. Before 0.3.5 the result depended on the database behind the store: on MySQL 8 such a duplicate was missed, or only one product of the pair was listed.
One case stays out: two variations sharing a number, of one product or of two, while neither parent product carries that number. A finding belongs to a product, and there is nothing to attach it to there. Drafts never count either: Merchlint compares published products and their variations only.
Why a product and its own variation so often carry the same number. Importers build a variable product by cloning its first variation, or by copying the parent’s fields onto it, and the number travels with the rest. WooCommerce would refuse that pair when you save the product yourself—since 9.2 the field has to be unique across products and variations—but an import writes it straight to the database, so nothing flags it. It matters when your feed exports the parent alongside its variations: then two items go out with one number. Clearing the number on the parent is the safe fix, because a variable product is judged by its variations.
Translations are resolved before grouping: two language versions of one product count as one, so a bilingual store does not receive two findings for every translated pair.
Unlike the missing-identifier check, this one has no catalog-wide threshold. A missing identifier can be a deliberate choice; a duplicate rarely is—someone had to enter the same number twice.
Confidence: F—fact from the database. No interpretation, no threshold.
This check runs in the free version, on every product, with no cap.
Doesn't match what you see in your store? Email us—we read every message. contact@merchlint.com