AMP Pages Tagging via Launch by Adobe
Before we get started, it's important to call out that this method supports the Visitor ID Service, Adobe Analytics page view tracking and Adobe Audience Manager. Adobe Target and link tracking are not supported with this approach.
Here's a link to the public facing technical guide I created that walks through how to do Adobe Analytics page load tracking on AMP pages. I'm going to reference certain components from it in this section.
Validate AMP Syntax
Add References to Libraries
- https://cdn.ampproject.org/v0/amp-analytics-0.1.js (Mandatory file for any kind of analytics tracking in AMP be it Adobe Analytics or Google Analytics.)
- https://cdn.ampproject.org/v0/amp-iframe-0.1.js (Required if you want to setup Adobe Analytics using any Tag Management solution such as Launch by Adobe)
Leverage the "adobeanalytics_nativeConfig" Template
This is the most important step in the overall configuration. This method makes use of the "adobeanalytics_nativeConfig" template to host the Launch by Adobe library in an iframe as well as outputs meta data required to pass data over to the Analytics tag.
There are two main components of the code as shown in the sections highlighted below.
Setup Adobe Analytics Extension in Launch
Install the Adobe Analytics extension in Launch.
- This method doesn't work on Adobe Target due to the iframe
- Link tracking doesn't work with the "adobeanalytics_nativeConfig" template
This section is based off the instructions provided in the official Adobe documentation. I've added a simple addition to show how to fire off events as a client asked about it which are not listed on this page. Let's go through the setup.
Link Tracking Code Setup
The screenshot below shows the code that we need to use to setup basic image pixel based page load and link tracking on AMP pages. At a high level, there are three main sections in the code.
- The "requests" section (Red) contains a definition of various Adobe Analytics variables that are referenced for the page view and link tracking image requests.
- The "vars" section (Blue) contains variables that are mandatory to send the image request such as tracking server and report suite.
- The "click" section (Orange) is where we define all variables needed to be sent as part of the link tracking call.
Validate Link Tracking
Below is a screenshot that shows the Adobe Analytics link tracking call.
Caveats with this Approach
There are lot of issues with this method which are taken from the test page hosted on Adobe's Github.
- Visitor/visit counts will be hyper inflated.
- Visitor ID Service is not supported.
- No way to tie a visitor back to the originating site (no measuring new vs repeat visitors or user acquisition).