If you want to track goals (e.g., purchases or sign-ups) on your website, you can use Google Tag Manager (GTM) to set up goal tracking. Here's how:
Prerequisites
To ensure that goal tracking works properly, you need to fire your "Wisepops setup code" tag before your "goal" tag. Here's how to adjust the tag priority:
Open the "setup code" tag in Google Tag Manager.
Click "Advanced Settings".
Set the "priority" of the "setup code" tag to 1.
In this tutorial, we'll assume you have a confirmation page associated with your goal. If you don't, please contact us, we'll suggest a different method.
Step-by-Step Instructions
Log in to your GTM account.
In the left-hand menu, click "Triggers" and then "New."
Configure your trigger using the following settings:
In the left-hand menu, select "Tags" and click "New."
Under tag configuration, select "Custom HTML."
In the HTML field, paste the Javascript snippet provided to you when you create a goal and customize it:
Replace the revenue value with a variable that make sense to you. You likely want to retrieve the revenue from your data layer.
In the triggering section, select the trigger you just created.
Name and save your new tag.
Preview the changes to make sure that the tag fires correctly on your confirmation page.
When finished, click "Publish" to apply the changes to your website.
If you have any questions, please get in touch.