Send Data from a HubSpot Form to Advocate
Once you’ve integrated Advocate with HubSpot, you can automatically track referrals with HubSpot forms. Referrals are tracked by placing a cookie on the website that your referral form is on. Brands using other setups will need to add the UTT to their landing page.
An active HubSpot integration is required to send data from HubSpot Forms to Advocate. Refer to Integrate with HubSpot for Advocate to get started.
Step 1: Create a lead capture form in HubSpot
- In HubSpot, create a lead capture form.
- Skip this step if you have an existing lead capture form you want to use.
- Make sure your form contains a field for
impact_referralcookies
. We recommend hiding this field from the interface.
Step 2: Copy your UTT
- From the left navigation menu, select Menu → Settings.
- On the right, below Program → Tracking, select General.
- Copy your UTT and save it somewhere you can easily access it, like a notepad app.
Step 3: Generate your referral attribution script
- In your impact.com account, from the left navigation menu, select Menu → Settings.
- On the left, below Advocate Settings, select Install.
- In the Use referral cookies section, select whether you’re using a HubSpot landing page or a custom landing page.
- Copy the resulting referral attribution script and save it somewhere you can easily access it, like a notepad app.
Step 4: Set up your landing page
Next, continue based on which type of landing page you're using.
HubSpot landing page
Note: Not all HubSpot landing pages support adding custom code. If yours does not, then you’ll need to use another type of landing page.
- In HubSpot, go to your landing page’s settings.
- Expand the advanced options.
- In the Additional code snippets box, add the UTT and the referral attribution script.
- Save your changes.
Custom landing page
- Paste the UTT and the referral attribution script on your landing page.
- In HubSpot, go to your form settings.
- Select Embed and find the
region
,portalId
, andformId
values. - Paste them into the referral attribution script on your landing page. There are instructions in the script to show you where to add this information.
Step 5: Optionally, test the form
Optionally, submit test information to the form to confirm that it’s properly attributing referrals. Make sure that:
- The lead is created as a new Advocate participant, if you’re using this data sharing rule.
- The contact in HubSpot contains Advocate properties like referral code, share link and message links.
Learn more
Updated 5 months ago