# HubSpot Integration

> Connect HubSpot forms and meetings to AnyTrack so leads, lifecycle events, and CRM conversions keep their original traffic attribution.

## What is the HubSpot Integration?

The HubSpot integration connects your HubSpot CRM with AnyTrack's attribution platform. This native integration automatically tracks form submissions, contact creation, meeting bookings, and deal progression without requiring third-party tools like Zapier.

**Key capabilities:**

* Track HubSpot form submissions as conversion events * Monitor contact lifecycle stages and deal progression * Attribute conversions to specific ad campaigns and traffic sources * Pass first-party data between platforms for improved targeting

<Prerequisites
  title="Before you begin"
  items={[
    { label: "You have an AnyTrack account with a paid subscription and Admin permissions", done: true },
    { label: "You have a HubSpot account with permissions to connect third-party integrations", done: true },
    { label: "You have at least one HubSpot form you want to track", done: true },
    { label: "Your leads are captured on HubSpot native forms — if you use external forms or a Zapier-type import, see the note below", done: true },
  ]}
/>

<Callout icon="❗">
  **What the native HubSpot integration means for AnyTrack** > > The native integration tracks **HubSpot's own forms**, where the AnyTrack Tracking Tag runs and stores the click ID in the AnyTrack Client ID field at session time. AnyTrack then matches the form submission back to that visit and attributes it to the right campaign. > > If you instead capture leads on an **external form** (Typeform, Jotform) or push contacts into HubSpot through **Zapier or Make**, that automatic link is broken — the contact is created with no tracked session and lands under [Unknown](/docs/conversions-showing-as-unknown). In that case, follow the [Form Tracking](/docs/form-tracking) guidelines: capture the AnyTrack click ID as a hidden field on the form and pass it into the HubSpot contact's AnyTrack Client ID property.
</Callout>

***

<Callout icon="🚧">
  **Beta** > > This HubSpot integration is currently in Beta and available to all customers at no additional cost. During this period, we are actively gathering feedback and making improvements. Learn about <a href="/docs/beta-features">Beta Features</a>.
</Callout>

## Why Use This Integration?

**Improve Attribution Accuracy** Connect customer actions in HubSpot directly to your advertising campaigns. See which ads, keywords, and channels drive actual leads and customers.

**simplifies Data Flow** Eliminate manual data exports and imports. Customer interactions flow automatically from HubSpot to your advertising platforms for better targeting and optimization.

**Optimize Marketing Spend** Make data-driven decisions about budget allocation by understanding which campaigns generate the highest-value leads and customers.

## How to Set Up the Integration

### Step 1: Install AnyTrack Tracking

Before connecting HubSpot, install the AnyTrack tracking tag (a JavaScript code snippet that collects visitor data) on your website.

1. **Copy your tracking tag** from the AnyTrack dashboard

<Image align="center" border={true} src={readmeAsset1} className="border" />

2. **Add the tracking tag to HubSpot pages**

<Callout icon="📘">
  **Using HubSpot CMS** > > This guide shows setup via HubSpot CMS. Also install the tracking tag via Google Tag Manager or directly on your website.
</Callout>

* In HubSpot, go to: **Settings > Tools > Content > Pages** * Paste the AnyTrack tracking tag in the header section

<Image align="center" border={true} src={readmeAsset2} className="border" />

* Click **Save**

### Step 2: Connect HubSpot to AnyTrack

1. **Navigate to the Integration catalog** in your AnyTrack dashboard

![](./ascreenshot-0ad2f93145.jpg)

2. **Search for HubSpot** and click the HubSpot card

![](./ascreenshot-6ae2345749.jpg)

3. **Click Install Integration**

![](./ascreenshot-1f3f587568.jpg)

4. **Select your AnyTrack property** (the website/domain you're tracking) and click **Next**

![](./ascreenshot-dc4c4bdf0d.jpg)

5. **Click Connect HubSpot** to authenticate your account

![](./ascreenshot-9b6ed07766.jpg)

6. **Select your HubSpot account** and click **Choose Account**

![](./ascreenshot-d01c8d9709.jpg)

7. **Review the permissions** AnyTrack needs and click **Connect App**

![](./ascreenshot-fff0cdd97a.jpg)

8. **Click Save** to complete the connection

![](./ascreenshot-4cd6a449fe.jpg)

### Step 3: Configure Form Tracking

After connecting, you need to add a special tracking field to your HubSpot forms.

<Callout icon="📘">
  **AnyTrack Client ID Property** > > During installation, AnyTrack automatically creates a custom property called **AnyTrack Client ID**. This unique identifier links form submissions to specific website visitors, improving attribution accuracy.
</Callout>

1. **Return to HubSpot** and edit the form you want to track

![](./ascreenshot-56bad221ef.jpg)

2. **Add the AnyTrack Client ID field**

* Add a new field to your form * Select the property **AnyTrack Client ID** * Set the field as **Hidden** (visitors won't see it)

![](./stack-animation-7346cdd200.webp)

3. **Click Review and Update** to save your form changes

![](./ascreenshot-9a54dca86d.jpg)

## What Events Are Tracked?

The integration automatically tracks these HubSpot activities:

| Event Type        | Trigger                              | AnyTrack Event Name    |
| ----------------- | ------------------------------------ | ---------------------- |
| Form Submission   | When a HubSpot form is submitted     | `FormSubmit`           |
| Contact Created   | When a contact is created in HubSpot | `Lead`                 |
| Meeting Scheduled | When a contact schedules a meeting   | `Schedule`             |
| Lifecycle Stages  | Contact reaches "Customer" stage     | `CompleteRegistration` |
| Lead stages       | When a contact lead stage is updated | Custom event names     |
| Deal Stages       | When a deal is created and updated   | Custom event names     |

<br />

## Related Resources

* [Advertising Integrations](/docs/advertising-integrations) - [MediaGo Integration](/docs/mediago-ads-integration) - [Outbrain Integration Checklist](/docs/outbrain-integration-verification-checklist)

<br />

<FaqAccordion
  title="HubSpot Integration - Frequently Asked Questions"
  icon="fa-duotone fa-circle-question"
  items={[
    {
      question: "What is the AnyTrack Client ID field in my HubSpot forms?",
      answer: "The AnyTrack Client ID is a custom contact property that AnyTrack creates automatically during installation. It stores a unique visitor identifier that links form submissions to specific website sessions, enabling accurate attribution of leads to ad campaigns and traffic sources."
    },
    {
      question: "Do I need to add the AnyTrack Client ID field to every form?",
      answer: "Yes. Add the AnyTrack Client ID as a hidden field to every HubSpot form you want to track. Without this field, AnyTrack cannot attribute the form submission to the correct visitor session and campaign."
    },
    {
      question: "Which HubSpot events does AnyTrack track?",
      answer: "AnyTrack tracks form submissions, contact creation, meeting bookings, lifecycle stage changes, lead stage updates, and deal stage progression. Each event type is automatically mapped to the corresponding AnyTrack event name."
    },
    {
      question: "Can I track deal stages and attribute them to ad campaigns?",
      answer: "Yes. When a deal is created or updated in HubSpot, AnyTrack captures the event and attributes it to the original traffic source. This lets you see which campaigns drive deals through your pipeline."
    },
    {
      question: "Does this integration work with non-HubSpot forms or landing pages?",
      answer: "The native HubSpot integration tracks HubSpot forms specifically. If you use non-HubSpot forms on your website, install the AnyTrack tracking tag on those pages and use the appropriate integration for your form platform."
    }
  ]}
/>
