How do I integrate Reveal into Google Analytics (analytics.js) via Tag Manager (GTM)?


How Can Reveal Help Me?

Reveal equips marketers with deep insights about their web traffic. Behind the scenes, Reveal dynamically links IP addresses with specific companies and their relevant firmographics & technographics.

It's especially useful for the following use-cases:

  • Knowing which companies are browsing your site in real-time, even if they haven't submitted a form.
  • Determining attribution & conversion statistics for key accounts and target segments.
  • Customizing engagement for key accounts or company profiles (by size, vertical, or even tech stack).
  • Delivering dynamically personalized content to your site visitors.
  • Reveal currently comes with a Google Analytics integration out of the box and takes all of 15 minutes to get up and running!

Create Custom Dimensions in GA

Step one is to create a set of custom dimensions within Google Analytics. You'll need to create a one-to-one mapping of Clearbit attributes to Google Analytics dimensions.

Navigate to  Custom Definitions and Custom Dimensions within the Google Analytics Admin panel. Create a custom dimension for each of the properties below, with a 'Scope' of 'Session'.


You can choose to create as many or as few dimensions as you think is helpful, however you can only have up to 20 in GA. Make sure you keep a note of the dimension numbers, you’ll need those later.  

(We do recommend adding as many of relevant Clearbit dimensions from the beginning as you can so there aren't any gaps in your analytics.)


Create Clearbit HTML Tag in Tag Manager

Open Tag Manager and navigate to the Container that has the Google Analytics tag. Create a New Tag and name it. Select the Custom HTML Tag option.

Next, you'll need to drop the below snippet into the code editor. You will need to change the mappings to reflect the custom dimensions you created above. In addition, you will need to add in your specific Publishable Key (note: this is different than your normal API key).  This code will push to all properties with a tracker name on the page. For specific ones, see this article.

ga_trackers = [];
ga.getAll().forEach(function(x, i) {
ga_trackers.forEach(function(gaName) {
ga(gaName + '.require', 'Clearbit', {
"mapping": {
"type": "dimension1",
"companyName": "dimension2",
"companyDomain": "dimension3",
"companyIndustry": "dimension4",
"companySubIndustry": "dimension5",
"companyEmployeesRange": "dimension6",
"companyEstimatedAnnualRevenue": "dimension7",
"companyAlexaRank": "dimension8",
"companyCity": "dimension9",
"companyState": "dimension10",
"companyCountry": "dimension11",
"companySicCode": "dimension12",
"companyTech": "dimension13"

<script async src="">


Next, you'll configure Tag sequencing in Advanced Settings. Specifically, you will want to make sure the primary GA tag is firing before the new Reveal tag and that the Reveal tag should not be fired if the GA tag fails or is paused. From there, set the Firing Triggers to Page views upon All Pages. An example screenshot is below:



Additional Resources:

Build a Google Analytics Dashboard with Clearbit Reveal Data