Sending "utm_" parameters with pixel [tutorial]

Sometimes we are asked the question like the one below:

I want to know if it’s possible to send utm_ params using pixel. In normal clicks, utm_ params get parsed automatically. I was wondering if that could be achieved with pixel as well.

That is possible indeed. The utm_ parameters need to be passed on the querystring of the page URL. So you would need to set the url parameter on the pixel. It could be set to a dummy value e.g.


and make sure the querystring on that is url encoded i.e.


You could use this online tool for the task.

Pixel tracker

The Pixel tracker is an HTML-only tracking tag (no JavaScript). In a normal JavaScript tag, the name-value pairs of data that are sent through to the Snowplow collector via the querystring are calculated on the fly by the JavaScript. In an environment where JavaScript is not permitted, these values need to be set in advance, and hardcoded into the tracking tag.

Campaign tracking with Snowplow

Snowplow uses the same query parameters used by Google Analytics. Those parameters are:

  • utm_source - Identify the advertiser driving traffic to your site e.g. Google, Facebook, autumn-newsletter etc.
  • utm_medium - The advertising / marketing medium e.g. cpc, banner, email newsletter, in-app ad, cpa
  • utm_campaign - This can be a descriptive name or a number / string that is then looked up against a campaign table as part of the analysis
  • utm_term - Used for search marketing in particular, this field is used to identify the search terms that triggered the ad being displayed in the search results.
    utm_content - Used either to differentiate similar content or two links in the same ad. (So that it is possible to identify which is generating more traffic.)

Further reading:

Putting it all together

Here’s a summary what is required to send the utm_ parameters using pixel:

  • An event to be attached with the pixel tag
  • The utm_ parameters of our interest
  • The encoded (dummy) url containing the utm_ parameters as querystring


<!--Snowplow start plowing-->
<img src=""/>
<!--Snowplow stop plowing-->

The above tag could be embedded into emails sent out as part of the marketing campaign. Note that I used

  • our Clojure collector’s pixel as the endpoint
  • the pageview event (e=pv)
  • the utm_ parameters descibing the campaign, namely:
  • utm_source=Facebook
  • utm_medium=banner
  • utm_campaign=Fall sale

When the email is opened the pixel will be fetched and the event recorded with all the utm_ parameters.

1 Like