Integrate with Third-Party Analytics

Monetate doesn't report data for Product Recommendations for Email experiences nor Full-Page Test experiences to third-party platforms. Depending on your site structure, you may need to use JavaScript polling to ensure that Monetate correctly captures your site's data.

In addition to experience analytics available in the Monetate platform, you can integrate your Monetate account with third-party platforms to report experience information. Examples of these platforms include Google Analytics, IBM Digital Analytics (formerly Coremetrics), and Adobe Analytics, including Adobe Marketing Cloud.

How Integrations Work

Exporting data to a third-party platform may add server calls to your system.

For traditional Monetate tag–based experiences, Monetate writes to a client's webpage the campaigns JavaScript variable. It contains the experience ID, name, and split information for every experience running on that page for the site visitor viewing it. By default, experience data is pushed when a site visitor sees an experience and after a 5-minute interval on the next track, be that a new page load or a retrack.

If you want a custom interval for reporting label pushes, such as having labels pushed on every page load (every track) or every 30 minutes, then submit a support ticket using the and provide the name of the report for which you want to customize the interval.

Monetate provides ready-made options if you need to integrate your account with Contentsquare or Google Analytics. You can use your own JavaScript or use integration tools provided by other analytics platform vendors. If you’ve developed your own analytics-tracking tools, you can use them as well.

See Enabling a Custom Report at the Experience Level in Configure a Custom Third-Party Analytics Report in the Monetate Knowledge Base for more information about sending experience data to your third-party analytics platform(s).

The campaigns Variable

The campaigns JavaScript variable is an array of objects that contains information about the experiences running on a page of your site. It sends the experience data to your third-party analytics platform(s). The number of indices in campaigns is equal to the number of experiences the site visitor sees on the page.

Monetate writes the campaigns variable on a page of your site, but the variable doesn't provide other functionality by itself. Submit a support ticket using the if you have questions.

Each object in the campaigns variable contains the following information:

  • id — The unique experience ID, which doesn't change (for example, 217022)
  • key — The experience name shortened and appended with the experience ID (for example, Winter-Sale_217022); changes if you change the experience name
  • split — The split name (for example, Experiment or A-control)

Here is an example of the data present in the campaigns variable for a visitor who was exposed to three different experiences on the page.

Code sample of data from multiple experiences captured in the 'campaigns' variable


The following code snippet places the array in a variable available on the front end:

campaigns Variable Code Example


The following screenshot shows how to access the campaigns variable in your console.

A JavaScript console that shows the 'campaigns' variable


Session Count Discrepancies and Data Validation Checks

Session counts between Monetate and your third-party analytics platform will always have discrepancies due to various factors. Instead of focusing on session matching, Monetate strongly encourages you to conduct a purchase audit to match purchases between platforms because consistent collection and alignment of purchase data signifies a healthy Monetate implementation.

Session counts between Monetate and a third-party analytics platform may vary for various reasons:

  • Differences in session definitions and handling between Monetate and the third-party analytics platform
  • Variances in bot traffic–filtering mechanisms between Monetate and the third-party analytics platform
  • Varied session timeout and activity limits set by different analytics systems
  • Inclusion of nonessential analytics cookies that may be blocked by visitors

By conducting a purchase audit to align purchase data between Monetate and your third-party analytics platform, you can ensure data accuracy and obtain more meaningful insights for analysis.

Requesting a Purchase Audit

To initiate a purchase audit, contact your Customer Success Manager, who can guide you through the process and provide you with the necessary details regarding the data you need to provide for the audit. You can also find more information in the Data Alignment Check section of Test an Implementation.

Testing the Integration

After you create the custom third-party analytics reporting integration following the steps in Configure a Custom Third-Party Analytics Report, you can ensure it works by adding the JavaScript console.log() method and a message to the code in the editor on the report configuration page in the Monetate platform.

The following example is the minimal Google Analytics 4 with Google Tag code with the console.log() method added.

GA4 with Google Tag with console.log() Example


After you add the console.log() method and message to the report code, click the preview icon.

Callout of the preview icon for a for a Google Analytics 4 report configuration


While viewing the new browser tab or window in which your site loaded in Preview Mode, open your browser's developer tools, switch to its console, and ensure the message that you used with the console.log() method in the report code is present.

Callout of the 'Google Analytics 4' message resulting from the 'console.log()' method used in the GA4 report's code


When you've confirmed that the integration works, you can enable it for all new Web experiences as well as add it to any active Web experiences. Refer to Enabling a Custom Report at the Experience Level in the Monetate Knowledge Base for the steps.