NewProduct Score, 4T Segmentation, Price War and Broken Size are live.See what's new
Feedance
Article

Adding cost_of_goods_sold to Your Google Feed: A Playbook From COGS Export to Margin Tiers

A step-by-step playbook for adding cost_of_goods_sold to a Google product feed, matching cart data IDs, and turning gross profit into margin tiers.

Cagdas PolatCagdas Polat
9 min read

Most Performance Max reports tell you revenue and ROAS. Few tell you gross profit, because Google can only calculate it when each product in your feed carries a cost. Google states that this cost is allowed to be rough: its own setup guide suggests estimating COGS as 80% of the product price when you do not have exact figures. This guide is for feed managers and paid media leads who have a cost column somewhere (an ERP export, a supplier price list) and want it inside the Merchant Center feed. By the end you will have a correctly formatted cost_of_goods_sold attribute, a conversion tag that matches it, and a first margin report you can turn into custom label tiers.

What cost_of_goods_sold does and does not do

cost_of_goods_sold is a Merchant Center attribute that supports gross profit reporting. Google describes gross profit as revenue minus COGS. The attribute does not change which products are approved, how they rank, or what you bid. It only gives Google Ads a cost to subtract from the revenue it already records for each sold item.

It is optional for most merchants. Google lists it as required only for automated discounts and dynamic promotions. For everyone else, it is a reporting upgrade, and the reporting only works if the conversion tag also sends item-level cart data.

The attribute is not a bidding setting, and Feedance does not manage bids. What the data gives you is a reliable view of which products and campaigns make money, so the structure and budget decisions you make elsewhere rest on profit rather than revenue.

Step 1: Decide where each product's cost will come from

Google accepts exact values, averages, and estimates, so the first decision is which source you trust enough to maintain. We rank the options below by how often they stay accurate after the first month.

Cost sourceAccuracyMaintenance burdenUse when
ERP or inventory system export, per SKUHighLow once automatedCosts are already stored per variant
Supplier price list joined on SKUMedium to highMedium; lists change per seasonNo ERP, but a clean supplier file
Category average (for example 0.62 x price for one category)MediumLowMargins are uniform inside a category
Flat percentage of price (Google's example: 80%)LowNoneYou need a first report this week and will refine later

A flat percentage produces gross profit that moves exactly with revenue, so it will never tell you that one product earns more per sale than another. Use it to switch the reporting on, not to make margin decisions.

Step 2: Format the attribute exactly

Google's specification for cost_of_goods_sold is a number plus an ISO 4217 currency code, not repeated, with a period as the decimal separator. Failing either rule can make products ineligible for reporting, which produces incomplete data.

In a tab-delimited feed the value looks like this:

412.50 TRY

In XML:

<g:cost_of_goods_sold>412.50 TRY</g:cost_of_goods_sold>

Use the same currency for COGS as the price your conversion tag reports. Google recommends this to avoid inconsistencies from exchange rates. Merchants selling in Turkish lira with a supplier invoicing in euros need to convert cost into lira inside the feed before export, using a rate you refresh on a schedule.

These are the formatting mistakes we see most often in cost columns, and what each one does:

Source valueProblemCorrected value
412,50 TRYComma decimal separator, common in Turkish locale exports412.50 TRY
412.50No currency code412.50 TRY
TL 412.50Not an ISO 4217 code, wrong order412.50 TRY
1,412.50 TRYThousands separator inside the number1412.50 TRY
0.00 TRYEmpty cost exported as zero, which reads as 100% marginLeave the attribute out for that product

The last row is a judgement call rather than a Google rule. A zero cost is a valid number, so Google will accept it, and it will inflate gross profit for that item. We omit the attribute when the cost is unknown.

Step 3: Deliver the value to Merchant Center

Google lists three ways to provide COGS data: your product feed, the Content API (and its Merchant API successor), or a supplemental feed. The supplemental feed route is usually the safest when the cost data comes from a different system than the product catalog, because you can ship a two-column file (id and cost_of_goods_sold) without touching the primary feed.

If you manage feeds with a platform, the equivalent is a layer that adds an attribute without rewriting the source. In Feedance this is what supplementary feeds are for, and feed rules can calculate a category-average cost from price when you are using an estimate. We have not published a client example of this specific use, so treat the mechanics as the ones described on those feature pages.

Step 4: Check that cart data lines up with your feed IDs

The cost is only used when Google can match a sold item to a feed item. Google's help states that item IDs in the conversion tag's items array must exactly match the id attribute in your Merchant Center feed, and that only items from a Merchant Center account linked to the Google Ads account are processed. Eligible conversions must be biddable purchase conversions using the Google tag or Google Tag Manager.

Run this checklist before you wait for data:

  1. The Merchant Center account is linked to the Google Ads account that owns the purchase conversion.
  2. The purchase tag sends an items array with an ID, a price and a quantity for every line item.
  3. The ID in the tag is the same string as the feed id, including case and any variant suffix. If your tag sends the parent SKU and your feed uses variant IDs, nothing matches.
  4. The price in the tag uses the same currency as the COGS values.
  5. The conversion action's diagnostics show no unmatched-ID warnings. Google points to this diagnostics section for finding mismatches.

Item ID mismatches are the most common reason a COGS rollout shows dashes instead of numbers. Google notes that with no COGS attribute, COGS and gross profit values appear blank or as a dash in reports.

Step 5: Read the first report and check it against your finance numbers

Google Ads exposes the results as gross profit, gross profit margin, cost of goods sold, revenue and units sold. For Performance Max, the Google Ads API documents these metrics as metrics.gross_profit_micros, metrics.gross_profit_margin and metrics.cost_of_goods_sold_micros, available in asset_group_product_group_view, campaign, customer and shopping_performance_view.

Two caveats from the API documentation affect how you read early numbers. Cart data metrics are not available until all conversions have been recorded for the associated products, so the first days will look incomplete. And starting June 15, 2026, shopping_performance_view includes data from all Performance Max networks, not only the Display Network, so metrics may rise once when that data is added. If you compare a before and after, do not treat that one-time step as an effect of your feed change.

Validate with a sanity check: pick a week, take the revenue Google Ads attributes to cart data, subtract your finance team's cost for the same products, and compare. Expect a gap if your COGS is an average. Do not expect it to be zero.

Step 6: Turn gross profit into margin tiers

Once gross profit margin is visible per product, group products into a few tiers and write the tier into a custom label. Google allows custom_label_0 to custom_label_4, each up to 100 characters, with one value per product per attribute, and up to 1,000 unique values per label. Three to five tiers is enough.

An illustrative scheme (the numbers are examples, not benchmarks):

Gross margin on feed pricecustom_label_1 valueTypical use
Below 20%margin_lowSeparate listing group; judge on profit per click, not ROAS
20% to 40%margin_midDefault group
Above 40%margin_highCandidate for more budget
No COGSmargin_unknownReview list; fix the data

The tier is a feed-side calculation from price and cost_of_goods_sold, so a feed rule can write it automatically each time the feed is rebuilt. Our earlier piece on custom labels, product type and item ID for Performance Max listing groups covers how many label dimensions a listing group tree can bear before it fragments. If you want to check whether the change helped, our method for measuring a feed change against ROAS applies unchanged.

Step 7: Keep the cost column alive

Cost goes stale faster than price. Put an owner and a refresh cadence on it. Re-export after every supplier price change, every currency movement that matters to your margin, and every season. A product whose cost rises above its price should show a negative margin in your own check before it ever reaches a report.

Where this breaks down

COGS reporting measures gross profit on the sold items. It does not include shipping subsidies, returns, payment fees or ad spend, so a product can show a healthy gross margin and still lose money. Google's own SA360 documentation gives the example of wholesale cost before tax, shipping and advertising costs, which confirms that scope.

It also depends on cart data being implemented correctly, and it needs the purchase to be a conversion that Google can attribute. Only purchases reported as conversions with cart data can appear in these metrics.

Averages hide variance. If one category mixes a 15% margin accessory with a 55% margin core product, a category average will misreport both.

Competitors cover this too. DataFeedWatch publishes a guide on adding cost of goods sold to a feed for gross profit reporting, and platforms positioned around product profitability, such as ROI Hunter, may suit you better if profit logic is your main need (see our comparison). Feedance prepares the data; it does not set bids or budgets from it.

FAQ

Is cost_of_goods_sold required for Google Shopping?

No. Google treats it as optional, except for automated discounts and dynamic promotions where it is required. Without it your ads run normally, but COGS and gross profit metrics show as blank.

Does the cost have to be exact?

No. Google says the data is for reporting and does not need to be exact. If cost varies by product, provide an average, or a rough estimate such as 80% of price.

Can customers see the cost?

Google describes the attribute as a reporting input used when conversions are reported with cart data. Its documentation does not present it as ad content, but we have not tested every surface, so confirm in your own account.

Why do my reports show a dash for gross profit?

Usually either the attribute is missing or the IDs in the conversion tag do not match the feed id. Check the conversion action's diagnostics for mismatched IDs first.

Which currency should I use?

The currency of the price your conversion tag reports. Google recommends matching them to avoid exchange rate inconsistencies.

Does it work with Performance Max?

Yes. The Google Ads API documents cart data metrics, including gross profit and gross profit margin, for Performance Max campaigns where Conversions with cart data is implemented.

Where do I add it if I do not want to edit the main feed?

Use a supplemental feed or the Content or Merchant API. Google lists these alongside the primary feed as accepted delivery methods.

How is this different from custom labels?

The cost attribute feeds Google's profit reporting. A custom label is a segment you define for campaign structure. You use the first to calculate margin and the second to act on it.

Check your feed before you add the cost column

A cost column only helps if the rest of the feed is sound. Run your feed through the free product feed audit tool to find missing and malformed attributes before you build margin tiers on top of them.

Sources

Want a second pair of eyes on your feed? We will review it with you and show where the gaps are before your next submission.
Run a free audit
Cagdas Polat
Written by
Cagdas Polat

Co-founder of Feedance, where he leverages his background as a computer engineer and marketer to drive analytical insights. With a strong focus on transforming data into actionable strategies, he is dedicated to helping brands achieve significant growth in the digital landscape.

LinkedIn

See which
products earn.

Connect your feed and GA4. We show Product Score, 4T, Price War and Broken Size on your own catalog.