APIs & Integrations

ASavaliya
Participant

How to prevent creating contact through Tracking code identity

Hi All,

 

I am using tracking code for track this visitor, but when I am set identity as user email and fire 'trackPageView' event then this event create new hubspot contact, so I want to prevent this.

 

Thanks & regards 

Ankur savaliya

0 Upvotes
9 Replies 9
JLaPaglia
Participant

How to prevent creating contact through Tracking code identity

I found the answer in another thread, despite this thread showing up higher in SEO:

 

NonHS Forms on website(s) are automatically creating Contacts - How to stop?

This is probably because you are using our Non HubSpot Forms tool. You can toggle that off in Settings > Marketing > Forms > Non HubSpot Forms. You have more information on this in the following article: 

Use Non HubSpot Forms 

 

This is a all-or-nothing tool. You cannot select some external forms but not the others. If this is something you really want to do, I'd advise to use our Forms API



https://community.hubspot.com/t5/CRM/NonHS-Forms-on-website-s-are-automatically-creating-Contacts-Ho...

 

Hope it helps.

ASavaliya
Participant

How to prevent creating contact through Tracking code identity

HI @derekcavaliero 

Whenever users refresh the page then track the page again call by automatically. then it will create new contact.

0 Upvotes
derekcavaliero
Top Contributor | Diamond Partner
Top Contributor | Diamond Partner

How to prevent creating contact through Tracking code identity

@ASavaliya HubSpot's tracking script will automatically track page visits for you without trying to re-invent the wheel. You shouldn't need to use the identify call at all. 

Derek Cavaliero
Director of Engineering

WebMechanix
www.webmechanix.com
ASavaliya
Participant

How to prevent creating contact through Tracking code identity

Hi @derekcavaliero 

 

I am trying to track page visit count for contact. So I need one property of contact to identify to this contact has visited this page.

So If I am using Email then it creates a new contact, So if I use Id, then I  think we need to custom field for that.

 

0 Upvotes
derekcavaliero
Top Contributor | Diamond Partner
Top Contributor | Diamond Partner

How to prevent creating contact through Tracking code identity

Unfortunately, I don't understand what you are trying to achieve with the identify tracking code API @ASavaliya

Derek Cavaliero
Director of Engineering

WebMechanix
www.webmechanix.com
0 Upvotes
ASavaliya
Participant

How to prevent creating contact through Tracking code identity

Hi @derekcavaliero 

So I need to create custom property?

0 Upvotes
derekcavaliero
Top Contributor | Diamond Partner
Top Contributor | Diamond Partner

How to prevent creating contact through Tracking code identity

@ASavaliya The identity API will always create a contact if an existing record for that email address does not exist in the system. That behavior cannot be changed.

 

If you don't want to create contacts unless they interact with webforms - I would not suggest using the identity API. Most HubSpot installations don't need to make use of the identify API to properly track user interactions.

 

https://legacydocs.hubspot.com/docs/methods/tracking_code_api/identify_visitor

Derek Cavaliero
Director of Engineering

WebMechanix
www.webmechanix.com
ASavaliya
Participant

How to prevent creating contact through Tracking code identity

Hi @dennisedson 

I am trying to track my website visit count with the identity of the user email. So I set identity while the user visits a page. So when I set identity then it will check in Hubspot to identify contact, if this email is not found In Hubspot then it will create contact, So I want that if contact is not found in HubSpot it track as an anonymous user and don't create a new contact.

0 Upvotes
dennisedson
HubSpot Product Team
HubSpot Product Team

How to prevent creating contact through Tracking code identity

@ASavaliya 

What exactly are you trying to do?

@RMones , @derekcavaliero , either of you able to help?

0 Upvotes