Table of contents

How do you set up Pinterest Event Deduplication?

pinterest-event-deduplication-set-up-google-tag-manager

The use of Pinterest server-side tracking(Pinterest Conversion API) is gaining ground within the digital marketing industry. This technique counteracts pixel-blocking caused by ITPs and AdBlockers, thus increasing the lifetime of Pinterest cookies, which is essential for accurate data analysis. When measuring Pinterest data on both the client side and the server side, some events may be measured twice. Pinterest would like to distinguish between events coming from the pixel and those coming from the conversion API, in order to achieve purer data analysis. That's why Pinterest has introduced a "Unique Event ID. In this article, we explain how to apply Pinterest event deduplication by setting it up in Google Tag Manager. This includes setting up event deduplication both on the client side and on the server side to create an optimized and efficient tracking system.

Note: This blog is only about Pinterest. Deduplication is not required for most other tags unless otherwise noted.

Curious about the entire Pinterest Server Side Tracking setup? Then check out this page.

Pinterest Event Deduplication set up

pinterest-event-deduplication-set-up

Set up Pinterest Event Deduplication in Google Tag Manager (both client and server side)

Total Time: 10 minutes

Step 1: Create variable (web container)

Default-workspace-webcontainer-variables

First we set up the required variable before proceeding with the configuration. In the web container (client side), go to 'Variables' and click 'New'. Have you already created these, for example by setting up Meta Event Deduplication? Then go to step 3.

Step 2: Set variable (web container)

create-unique-event-id-variable-gtm-webcontainer

Click Variable configuration and choose Discover more tag types in the Community Template Gallery. Search for unique event id and add Unique Event ID to the workspace. Name the variable Event ID and save.

Step 3: Select Pinterest pixels (web container)

web-container-google-tag-manager-tags

Go to Tags within the web container and click Pinterest Pixel. Not set up a Pinterest Pixel yet? Then check out this blog. In this example, we are using a template. Due to the transition from UA to GA4, you need to create multiple tags for each event you want to measure. Do you have multiple Pinterest Pixel tags? Then add event_id to each tag as described below.

Step 4: Set Pinterest pixels (web container)

pinterest-page-view-tag-set-up-google-tag-manager-web-container

Under Event to Fire, choose the event you are measuring with the pixel. In this example, we will use page_view. Under this event, select Page Visit. Check Custom Parameters. Enter event_id under Name and add your Unique Event ID variable under Value. Save the tag.

Step 5: Set up GA4 configuration tag (web container)

google-tag-ga4-configuration-event-deduplication

Go to Tags → Google Tag. Under Configuration parameter, add the following parameter: event_id - {{Event ID}}. Save the tag and Pinterest is deduplicated on the Client Side.

Step 6: Set up GA4 Events tags (web container)

google-tag-manager-workspace-tags-web-container

Repeat for all GA4 Event Tags. When all tags are set, click Submit at the top right to put the container live.

Step 7: Create new variable (server container)

variables-server-container-workspace-gtm

You have now set up Pinterest event deduplication client side, good job! Now we still need to deduplicate Pinterest in the server container (server side). In the server container, go to Variables and click New.

Step 8: Set variable (server container)

Set-up-event-id-variable-server-container-gtm

Click on the pencil icon. Click on Event Data and select it. Under key path, enter event_id. Give the variable a name, for example Event ID. Save the variable. Don't see Event Data listed? Then you're probably working in the client-side container instead of the server container.

Step 9: Select Pinterest Conversion API (server container)

select-pinterest-conversion-api-server-container-gtm

In the server container, go to Tags and select Pinterest Conversion API. Not created a Pinterest Conversion API yet? Then go to this blog.

Step 10: Customize Pinterest Conversion API (server container)

set-up-pinterest-event-deduplication-pinterest-conversion-api-tag-gtm-server-container

Click Override client data under Event Data. Under Parameter Name, make sure that Event ID is the value. Under Parameter Value, add the created variable.

Step 11: Putting container live (server container)

Now put the server container live et voilla: your first Pinterest Conversion API implementation! You have now gone through the entire Pinterest implementation sequence, nice going! From now on, all events from Pinterest will be measured and deduplicated both client side and server side.

About the author

Recently published

magnifiercrossmenu linkedin facebook pinterest youtube rss twitter instagram facebook-blank rss-blank linkedin-blank pinterest youtube twitter instagram