Using a form submission to convert a visitor into a lead

  • 15 July 2021
  • 6 replies

Intercom's Visitor model captures info about anonymous website browsers like pages viewed and their UTM source info. This is super valuable and if they send a message through Intercom the visitor is converted into a Lead so you can see all of that valuable info.


What I can't figure out is how to convert a Visitor into a Lead using a form submission. Intercom does not offer any form tools so the form necessarily must sit elsewhere. I am happy to use most form builders (Typeform, Google, etc). As it happens I'm currently using Unstack's built in form tool. All of these form tools allow you to create a new Lead in Intercom using Zapier but this is not connected to the Visitor so it provides none of the valuable intelligence about the person's journey before they completed the form.


Are there any ways, ideally using no code tools like Zapier, to convert a visitor into a lead when they complete a website form?


When I was exploring GoSquared they offered a method to do this by adding the following code to the form page so that GoSquared captured the completed form fields. Is something similar possible with Intercom?


GoSquared example code:

document.getElementsByTagName('form')[0].addEventListener('submit', function(evt){
let first_name = document.getElementsByName("first_name")[0].value
let last_name = document.getElementsByName("last_name")[0].value
let email = document.getElementsByName("email")[0].value
let organization = document.getElementsByName("organization")[0].value
_gs('identify', {
email: email,
first_name: first_name,
last_name: last_name,
custom: {
organization: organization



Best answer by Eric Fitz 21 July 2021, 12:49

View original

6 replies

Userlevel 1

Hey @andy p​, is our Convert a Visitor API endpoint of any use to you here? You can use it to convert visitors to leads. More information here.

Thanks @eric f11​. I think the link is wrong. If you can correct I'll take a look.

Userlevel 1

My sincerest apologies, it most certainly was wrong! It's been corrected now.

Hi team, I've been trying to solve this problem on and off for the last few months and no success. I'm not well versed in code. Is there a simpler instruction available somewhere?

Userlevel 1

Hey @sachee​, what type of form do you currently use to gather leads?


I’d like to know the answer to this question too. 2 years on. Any new ideas on this one? Thanks