Google Analytics API Automated Reports
Updated over a week ago

Important Note: Reminder that Google Analytics 4 replaced Google Analytics Universal July 1, 2023. To ensure your performance tracking data can continue to be sent to Zemanta, please make sure to switch your connection from Google Analytics Universal to Google Analytics 4 API in the Campaigns Settings. To learn more about how to make the switch please follow the steps described HERE.


Zemanta leverages the Google Analytics API to ingest your post-click metrics. This guide walks you through a simple two-part setup process in Zemanta and your Google Analytics account. Make sure to follow both of them accordingly.

Make sure tracking parameters are appended to every ad URL when using click trackers / click commands: In order to track first-party analytics data (Google Analytics), Zemanta has to append its tracking parameters to every content ad URL. The parameters are expanded on Zemanta's redirector and captured by the analytics on the landing page. Learn more here.

Part One: Setup in Zemanta

1. Select the Campaign that you want to integrate with Google Analytics.

2. Open the Settings drawer.

3. Mark the checkbox for Enable Google Analytics Performance Tracking in the Performance tracking section.

4. Input the following information:

5. Click on the Save button.

Part Two: Setup in Google Analytics

1. Navigate to the Admin section of the Google Analytics dashboard.

2. Click on the Property Access Management

3. There, add a new user by clicking on the + icon.

4. In the Add roles and data restrictions window, enter Zemanta’s tracking email account-13@zemanta-api.iam.gserviceaccount.com and select the Viewer role for this case.


If you experience an issue with the above tracking email, please use: account-14@zemanta-api.iam.gserviceaccount.com

5. Click on the Add button and you're all done!

Zemanta can now automatically ingest your post-click metrics in real-time for all enabled campaigns. Should you ever need to delete this user, simply login to your account permissions and select Delete user.

Do you add custom views within your Google Analytics property?

If you are creating custom views within the Google Analytics account for the property that Zemanta is ingesting and you want Zemanta to ingest all of the data comprehensively, you have to be sure to follow the rule below.

Zemanta is able to ingest only the first view inline by default. In order to pull the whole set of data to effectively optimize towards your campaign goals, you have to make sure to have the first unfiltered view left untouched. Google Analytics creates the first unfiltered view by default for your property. Do not delete or add filters to this default view. We suggest you add new views instead and not edit the default one.


PLEASE NOTE: If you already modified the default unfiltered view and you want to make sure that Zemanta ingests all of the important reporting data, reach out to your CS representative or use the chat in the Zemanta dashboard.

Make sure

  • that the web property ID is on the actual landing page. On the landing page, right-click and select Inspect element. Go to the Network tab, reload the page and search for UA-.

  • The event is enabled and access is given to Zemanta inside the Web property ID in the Google Analytics account. Zemanta needs access to Read & Analyze at the web property ID level. Grant the access at the web property ID level.

  • If your Google Analytics tracking parameters are being appended to the URL. Same process as for the Automated email reports.

Data use & privacy

  • Zemanta's access to Google Analytics data is formally approved by Google.

  • Our system will only read Zemanta’s related data as it filters out data signals that do not contain Zemanta’s click ID (zpbid) or Zemanta Performance tracking codes (_z1_msid, _z1_adgid, _z1_caid) in the landing page URL.

  • For optimisation and audience segment-building purposes, Zemanta will only use contextual data based on clicks (ie. time of day, section, browser, etc.) and will not use the user’s personal data.

  • You are able to create a custom filter inside Google Analytics, that will automatically collect traffic generated only by your Zemanta campaigns. To create the filter first navigate to the Filter section in the view in which you want to create the filter and then include _z1_|zpbid| in the Filter Field.

PLEASE NOTE: If you are using workarounds, include this filter: _z1_|zpbid|.*z1[0-9]+[a-zA-Z].+?1z.* in the Filter Field.

Did this answer your question?