Universal pixels can act as conversion pixels and audience pixels on multiple pages at once. This lets you use a single pixel on different pages on your website, and even place that pixel before your conversions or audiences are set up.
For example, you might want to:
- add visitors to your sale page to an audience
- count users who make a purchase as a conversion
- count users sign up for your mailing list as a separate conversion and also add them to another audience
With universal pixels, you place a single pixel on all of your pages (as part of your site template, if applicable) and then set up rules to determine what fired the pixel and take an appropriate action.
Every rule pairs logic with an audience, conversion, or both. Let's say you want to use a pixel to add visitors to your sale page to an audience, as well as to track a conversion for users who make a purchase. You would place a pixel on both the sale page:
and the thank-you page for purchases:
You would then create two rules for the pixel:
one that looks for the sale page and adds those users to your audience
one that looks for the thank-you page and counts the conversion
You could create more complicated rules as well. For example, you could create an audience out of users who spent more than a certain amount or users who purchase a certain product.
Rules can add or remove users from multiple audiences, count multiple conversions, or update audiences and count conversions at the same time.
Using a Universal Pixel with Your Campaigns
Step 1: Place the pixel script on your pages.
Before you run your campaigns, place the pixel script on your website's pages. If your site uses a template, you should place the universal pixel code in the template so all your pages will fire the pixel.
If the pixel you want to use doesn't already exist, create it first. See Creating a New Universal Pixel.
In the Brands view, click Universal Pixels.
Click the Actions button for the pixel that you want to use and click Get Tags.
Select the type of tag that you want to use from the dropdown menu: Script or Image.
Note: Under normal circumstances, you should use script tags. When you use image tags, Enable user matching is not available and page URL detection is limited to the Referer header sent by the browser. As a result, page URL detection will not work as expected if the image is not included directly on the page (e.g. if it is loaded in an IFRAME).
In the Get Tags window, copy the Tag Code.
If you are deploying the Universal Pixel via a Google Campaign Manager Floodlight container tag, select Deploy Via Floodlight before you copy the code. This ensures that code includes the script required to collect revenue, transaction ID, custom variables, and page URL from Floodlight.
Place the pixel script anywhere in the HEAD or BODY section of your website's template or pages.
Optional: If your pixel rule uses parameters (key-value pairs) from your webpages, add these as data objects on the page (or in the template). You'll need to coordinate with the website team to set up any key-value pairs you want to use with your pixel.
When you use an image tag, user matching is not available, and page URL detection is limited to the Referer header that the browser sends. As a result, page URL detection will not work as expected if the image is not included directly on the page (e.g. if it is loaded into an IFRAME).
You can also use the URL from the Image Tag when using Universal Pixel to send mobile app data. Extract just the URL from the SRC attribute of the image tag. In this case, you must use the
cntr_ifa key or postback parameters. An IFA enables audience collection and conversion attribution, while a postback enables conversion attribution with the assistance of a mobile tracking platform. For more information about postback conversions, see Postback Conversion Tracking.
Step 2: Set up the pixel rules.
Pixel rule sets define what to do when a pixel fires. Should that view be considered a conversion? Should the user be added to an audience?
The rules you write can evaluate the URL of the page that fired the pixel or work with custom variables that you set up.
You can set up to 50 rules for each pixel.
Select a brand, and then Universal Pixels.
Click the Actions button next to the pixel Name and select Edit.
In the Edit Pixel dialog, add rules to capture information from the pages where you placed the pixel. Be sure to link at least one audience or conversion. See Universal Pixel Rules.
Once you've added a rule set, the audiences and conversions you linked will be updated when the pixel fires.