If you recently installed the Google Shopping channel on Shopify, you may have noticed rise in strange referrals in your Google Analytics reports: Product_sync and sag_organic for medium and campaign parameters.
Where do sag_organic and product_sync come from?
They come from Shopify’s integration with Google Shopping. Specifically from UTM tags added to the product’s link url. When Shopify uploads your product feed to Google Merchant Center, it appends the following UTM tags to the product:
UTM Tag | Value |
---|---|
utm_source | |
utm_medium | product_sync |
utm_campaign | sag_organic |
utm_content | sag_organic |
The following querystring is appended to your product’s link url:
&utm_medium=product_sync&utm_source=google&utm_content=sag_organic&utm_campaign=sag_organic
This usually causes traffic coming from free/organic Google Shopping listings to show up in analytics with a medium of product_sync and Campaign of sag_organic.
What is sag_organic?
The “SAG” in sag_organic stands for Surfaces Across Google.
These parameters are Shopify’s way of helping you track the organic free traffic coming from Google Shopping. The intention is to help you separate Organic Google Shopping traffic from Organic Google Search Traffic.
The ability to get granular is good. But changing default Google Analytics behaviour is often unwelcome (in particular when the change is unexpected).
The default behaviour in Google Analytics for Organic Google Shopping traffic is to include it in the google / organic bucket.
Is it possible to keep default Google Analytics behaviour unchanged, while still gaining the ability to track Organic Google Shopping traffic separately?
The best of both worlds
By leaving source and medium at their default values, and only changing the campaign UTM tag, we can keep default Google Analytics reports unchanged, while gaining the ability to track Organic Shopping traffice separately.
Additionally we can use the content utm tag to track which specific products are sending us traffic.
UTM | Default Value | Shopify Value | New Value |
---|---|---|---|
utm_source | |||
utm_medium | organic | product_sync | organic |
utm_campaign | (not_set) | sag_organic | shopping |
utm_content | (not_set) | sag_organic | product.title |
Step 1
Rewrite the UTM tags
- Go to Merchant Center > Products > Feeds
- Click on the Content API feed
- Click on the Feed Rules tab
- Click the big blue PLUS + button, type link in the field, and select link from the drop down.
- For Data Source, select Set to, type link and select link from the Primary Feed: Content API list.
- Click OK
- Set the default behaviour if the link is blank to “Leave Blank”
- Now go to Modifications > Add Modification
- Choose Optimize URL > Set Parameter
Function | Parameter Name | Value |
---|---|---|
Set Parameter | utm_source | |
Set Parameter | utm_medium | organic |
Set Parameter | utm_campaign | shopping |
Set Parameter | utm_content | title (processed attribute) |

- Click OK and look in the right side column preview to see if the link has been properly updated.
- Click Save as Draft and Apply

If you are using UTM tagging in your Google Ads campaigns, you *may* need to completely clear the UTM tags in Google Merchant Center. You can do this by creating an “Optimize URL” rule with “Remove Parameter” to remove each of the UTM tags individually.
Step 2
Set your Canonical Link
Fixing Shopify’s Partial Implementation
The major problem with the way Shopify implemented the UTM tags, is that they didn’t include a canonical_link as part of the feed. The canonical link ensures that only the “clean” version (without UTM tags) of the product link gets include into Google’s search index.
“If you use tracking parameters in your link attributes, it is recommend that you use the canonical_link attribute to provide a canonical URL. Use the canonical_link attribute to ensure that products are associated with the correct URL in the Google Search index.”
Google Merchant Center Help
https://support.google.com/merchants/answer/188492?hl=en
Add the Canonical Link
Assuming that you are still on the Feed Rules page in Goolge Merchant center:
- Click the big blue PLUS + button to add a new Rule and type canonical and choose canonical link from the drop down.
- For Data Source, select Set to, type link and select link from the Processed Attributes list.
- Click OK
- Change the default behaviour if canonical_link has no value to “leave blank”
- Add Modification > Find and Replace
Now we need to add two Find & Replace operations. One to remove the UTM tags and another to remove the Currency parameter that Shopify also appends.
# | Find | Replace | Advanced |
---|---|---|---|
1 | &?utm_.+?(&|$)$ | (leave blank) | Search as regular expression |
2 | ¤cy=(…) | (leave blank) | Search as regular expression |

- Click OK and look in the right side column preview to see if the new link looks nice and clean. It should only have the variant id in there.
- Click Save as Draft and Apply

Done!
You may need to wait a few hours for your feed to be update with the new values.