Set Up Reveal API with Google Tag Manager and the dataLayer

Last Updated: April 20, 2022

For pricing information, please fill out the demo-request form on our pricing page to get in touch with a sales representative.

If you have a Reveal API subscription, you will be able to push Clearbit data to the dataLayer. To easily do so, you'll just need to create the following tag inside of GTM.

Skip Ahead to: 

Set Up Your Custom Dimension in Google Analytics

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.

  1. Navigate to  Custom Definitions > Custom Dimensions in the Google Analytics Admin panel.
  2. Create a custom dimension for each of the properties you want to include, with a 'Scope' of 'Session'. Mark Active.

💡 Clearbit Tip: We recommend adding as many of relevant Clearbit dimensions from the beginning as you can so there aren't any gaps in your analytics. GA is not retroactive, so if your team thinks it may use some of this data in the future, it's best to go ahead and collect it if you have the dimension available. 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 total. We recommend these for best practice:

  • Clearbit IP Traffic Type
  • Clearbit Company Name
  • Clearbit Company Domain
  • Clearbit Industry
  • Clearbit Sub Industry
  • Clearbit Employee Range
  • Clearbit Estimated Revenue Range
  • Clearbit HQ City
  • Clearbit HQ State
  • Clearbit HQ Country

Within GA's custom dimension settings, you can use 'Parked' to indicate any unused Custom Dimensions that may have been accidentally created or previously used. You can rename these fields however you'd like so long as they are not duplicated.

How To Create Tag Inside Google Tag Manager

  1. In Google Analytics set up your Custom Dimension.
    💡 Clearbit Tip:  We highly encourage you to also include the traffic type by adding "reveal.type" as a custom dimension. This allows our team to help ensure a correct implementation. This is very different from the "company type" attribute.

    Attribute dataLayer variable
    Clearbit - Traffic Type reveal.type
    Clearbit - Company Name
    Clearbit - Company Domain
    Clearbit - Industry
    Clearbit - Sub Industry
    Clearbit - SIC Code
    Clearbit - NAICS Code
    Clearbit - HQ Country
    Clearbit - HQ State
    Clearbit - HQ City
    Clearbit - Estimated Revenue Range
    Clearbit - Employee Range
    Clearbit - Global Alexa Rank
  2. For each one of the custom dimensions above that you have created within Google Analytics, create a respective "Data Layer Variable" within Google Tag Manager.
    💡 Clearbit Tip: Here is an example for setting up Clearbit - Company name as a variable: The Data Layer Variable Name should use "". The Default Value and format value ("Convert false to...") should be set to "(Non-Company)":
  3. Create a Custom Event trigger with the Event name of Clearbit Loaded. This will be referenced later on.
  4. Create a Google Analytics Settings variable. Under More settings, we will map our Data Layer Variables to their respective Custom Dimensions. Be sure to update with the correct UA-Tracking ID and map the Data Layer variables to their corresponding Custom Dimension index inside of Google Analytics — the Dimension Values will be the same ones you created from Step 2.
  5. Select Tag on the left-hand menu and create the Google Analytics - Universal Analytics tag:
    Screenshot_2018-09-19_14.38.02.pngCheck the Triggering section to make sure the Custom Event trigger we created in Step 3 is there.
  6. Create a Clearbit Reveal Tag as displayed (copy-paste the text under the image and update with your key - this can be found in your dashboard under APIs):

    📝  Please note: If you want to change the triggering for this tag later on for a non-standard setup, you can.
  7. Save and Deploy your GTM tag.
function pushToDataLayer(response){
var reveal = {reveal:response};
dataLayer.push({event:"Clearbit Loaded"});
return true;
<script src="">