WP Pixel Integration with Google Tag Manager
Attention
The following instructions describe how to add the basic WP Pixel code (Embed Script). Depending on your setup, additional configurations may be required.
Please contact your account manager for more details.
Step 1: Access the GTM Panel
Log in to your Google Tag Manager account and select the appropriate container where you want to place the code.
Step 2: Add a New Tag
- Select the Tags tab from the left-hand menu.
- Click New to create a new tag.
- Enter a name, such as
WP Pixel
, to help identify it later.
Step 3: Configure the Tag
- In the Tag Configuration section, choose the tag type Custom HTML.
- In the HTML field, paste the following code:
Note
Make sure to replace PIXEL_ID
with the identifier assigned to your store.
<script>
!function(w,p,e,v,n,t,s){w['WphTrackObject'] = n;
w[n] = window[n] || function() {(w[n].queue=w[n].queue||[]).push(arguments)},
w[n].l = 1 * new Date(), t=p.createElement(e), s=p.getElementsByTagName(e)[0],
t.async=1;t.src=v;s.parentNode.insertBefore(t,s)}(window,document,'script',
'https://pixel.wp.pl/w/PIXEL_ID/tr.js', 'wph');
wph('init', 'PIXEL_ID');
</script>
Step 4: Set the Trigger
- Click Triggering.
- Select the All Pages trigger to fire the code on every page of your website.
Step 5: Save and Publish
- Click Save to store the tag configuration.
- Then click Submit to publish the changes.
Done!
Your WP Pixel has been successfully imported and configured 🎉