Fire the Facebook Pixel When a form is Submitted

Lisa Fockens Updated by Lisa Fockens

You can easily track leads collected by Wisepops in your Facebook Advertising analytics. We do this, we will use the Wisepops JS callbacks feature.

Prerequisite

The Facebook pixel must already be installed on your website, on the page where Wisepops will collect leads. Please follow this guide from Facebook to learn how to do this.

Track the lead event on Facebook

Once a Wisepops form is posted and the validation passes, we want to track the lead event on Facebook. 

Open your popup in the campaign builder. In the left menu, select JS.

Create a new callback, linked to the After form submit event:

Copy and paste the following snippet:

fbq('track', 'lead');

Since this callback is expecting JavaScript, the snippet does not need to be surrounded with <script>  tags.

Save your popup.

You're done! The pixel will be fired every time an email is submitted.

How did we do?

Dynamically Add a Custom Parameter to a Redirect URL

Forbid Disposable Emails in Your Signup Form

Contact