GA Connector integrates Google Analytics data with HubSpot contacts and sends to Google Analytics stats from your HubSpot deals, enabling users to:

  • Identify the source, medium and other Google Analytics information of your Contacts, helping you understand where your leads come from.
  • Import stats on closed deals and key datapoints to Google Analytics as events allowing you to see deals closed by your sales team and measure marketing performance more effectively (additional add-on).

Install:

1. Login at https://app.gaconnector.com/setup/hubspot/
Requires an active GA Connector account. In case you don’t have one yet, feel free to sign up for a 30-day free trial here.

2. Install GA Connector tracking code on your website
In our setup wizard, a piece of code will be provided to you. You need to add this on the <head> portion of your website and it needs to be placed on every page of your website, even on the pages without lead generation forms.You can also opt to install our GA Connector script via GTM in order to optimize how it loads.


3. Install the GA Connector App for HubSpot

3.1 Click on Install GA Connector App

3.2 Select your HubSpot account (portal)

3.3 Click Choose Account

3.4 Review the requested scopes on this screen. GA Connector requests access to read contacts and deals, and read and edit contact properties and forms.

3.5 Click Connect app

3.6 See the next section

Configure:

There are two main features of GA Connector that you can configure :

  1. GA to HubSpot – Identifies the source, medium and other Google Analytics information of your Contacts.
  2. HubSpot to GA (optional add-on) – Sends stats on closed deals and key datapoints to Google Analytics as events

1. GA to HubSpot

The script you’ve added to your website from the Install section identifies the tracking information about your web visitors and stores them via cookies in the browser.

In order to send this to HubSpot, you’ll need to create hidden fields to your forms and set the field IDs to the table below. You then need to map them to the corresponding custom fields that were created in HubSpot by the GA Connector App.

LabelInput IDLabelInput ID
All Traffic Sources all_traffic_sourcesLast Click Campaignlc_campaign
BrowserbrowserLast Click Channellc_channel
City (from IP address)cityLast Click Contentlc_content
Country (from IP address)countryLast Click Landing Pagelc_landing
First Click Campaignfc_campaignLast Click Mediumlc_medium
First Click Channelfc_channelLast Click Referrerlc_referrer
First Click Contentfc_contentLast Click Sourcelc_source
First Click Landing Pagefc_landingLast Click Termlc_term
First Click Medium fc_mediumLast Click Timestamplc_timestamp
First Click Referrerfc_referrerLongitudelongitude
First Click Sourcefc_sourceLatitudelatitude
First Click Termfc_termNumber of Website Visitspage_visits
First Click Timestampfc_timestampOperating SystemOS
Google Analytics CIDGA_Client_IDDevicedevice
Google Analytics Measurement IDGA_Measurement_IDRegionregion
Google Analytics Session IDGA_Session_IDPages Visited pages_visited_list
Google Click IdentifiergclidTime Spent on Website time_passed
IP Addressip_addressTime Zone time_zone

1.1 Setting up GA to HubSpot with HubSpot Forms

If you’re using HubSpot Forms, the GA Connector app for HubSpot can automatically add these fields to your form.

A sample form is also created when you install the GA Connector app. You can find this at HubSpot CRM dashboard > Marketing > Forms. You can duplicate and customize this according to your needs.

GA Connector HubSpot form

In case you already have a form, you can automatically add hidden fields to this using our HubSpot form setup wizard.

HubSpot Form setup wizard

Just select which form you want the hidden fields to be added and use the embed code generated by the setup wizard.

1.2 Integration with Non-HubSpot forms

If you are using other forms, here are the guides for integrating the forms that are the most popular among the clients of GA Connector:

Not seeing your form? Feel free to send us a message at [email protected] so we could help you check if your form is eligible for integration.

2. HubSpot to GA

  1. Login at app.gaconnector.com/dashboard/integration/crm-to-ga4
  2. Under Connection Settings, Enter the Measurement ID and API secret of the GA4 property to which you want the events to be sent.
  3. To create an API secret, navigate in the Google Analytics UI to:
    Admin > Data Streams > choose your stream > Measurement Protocol > Create

Use:

  1. GA to HubSpot – Whenever a contact is created from your configured lead generation forms, it should contain tracking information once it arrives in HubSpot.
    HubSpot Contact with GA Connector data
  2. HubSpot to GA – GA Connector will send an event to your GA property whenever a certain data point triggers on HubSpot. Events are sent to Google Analytics from HubSpot every 5-30 mins.
    Data PointEvent sent to GA4Parameter name sent to GA4
    When a Contact is created hubspot_contact_createdn/a
    When a Deal is createdhubspot_deal_createdn/a
    When a Deal's Amount is updatedhubspot_deal_amount_updated
    (sends the amount value to GA4)
    hubspot_deal_amount
    When a Deal's stage is updatedhubspot_deal_stage_updated
    (sends the stage value to GA4)
    hubspot_deal_stage
    When a Deal is closed wonhubspot_deal_closed_won
    (sends the amount value to GA4)
    hubspot_deal_closed_won_amount

    HubSpot to GA4 events

Uninstall / Disconnect:

To uninstall / disconnect GA Connector from your HubSpot account, follow the instructions in this HubSpot Knowledge Base article.

Uninstalling GA Connector will:

  • Remove any OAuth tokens stored on GA Connector and prevent any further synchronization between HubSpot and your Google Analytics account.

Note: Uninstalling GA Connector in HubSpot does not remove the GA Connector properties in the Contact object. This is to make sure that the Google Analytics data on your existing Contacts is not lost.

Once you have backed-up the data you want and you no longer need the properties, you can manually delete them by going to Settings > Properties.

Note: If you still have an active GA Connector subscription, uninstalling GA Connector in HubSpot also does not stop Google Analytics information syncing into new Contacts in HubSpot. In order to turn this off, you will need to remove the GA Connector script on your website.