Web Snippet: How It Works and Configuration

Capture leads from any website's forms with the JavaScript Web Snippet, including UTM parameters and custom field mapping.

Funcionalidades
2 min read
Mar 30, 2026

The Web Snippet is a JavaScript script that allows capturing leads from forms on any external website.


What Is the Web Snippet

The Web Snippet is a JavaScript code that:

  • Installs on any web page
  • Captures data from HTML forms
  • Automatically sends leads to Vixiees
  • Does not require advanced technical knowledge

Advantages

  • Works with any HTML form
  • Automatically captures UTM parameters
  • Flexible field configuration
  • No need for a custom API

Installation

Getting the Code

  1. Go to Settings > Web Snippet
  2. Copy the JavaScript code shown
  3. This code includes your unique account key

Installing on Your Website

Paste the code in your website:

  • Before </head> or
  • Before </body>

Allowed Domains

Optionally, configure which domains are accepted for data for added security.


Field Mapping

For Vixiees to understand form data, you must map the fields.

How to Map

  1. Go to Settings > Web Snippet > Configuration
  2. Add a mapping for each form field:
  3. Save changes

Example Mapping

HTML Field (name)Vixiees Field
first_namefirst_name
last_namelast_name
emailemail
phonephone
companycompany_name

Required Fields

Each form must send at least:

  • Email or
  • Phone

Without these fields, the lead is ignored.

Custom Fields

You can map fields to custom Vixiees attributes by checking the corresponding option.


Automatically Captured Data

In addition to the form fields, the snippet captures:

DataDescription
Source URLPage where the form was submitted
UTM parametersutm_source, utm_medium, utm_campaign, etc.
GCLIDGoogle Click ID (if present)
Query stringURL parameters

Assignment to Sales Brains (Playbooks)

You can configure different Sales Brains (Playbooks) depending on the form.

By Form Identifier

  1. Add the id attribute to your HTML form
  2. In Vixiees, create a relationship: Form ID → Sales Brain (Playbook)
  3. Leads from that form will go to the configured Sales Brain (Playbook)

Example

Form IDSales Brain (Playbook)
contact_formSales
demo_requestDemos
newsletterMarketing

Without Configuration

If the form has no configured relationship, the default Sales Brain (Playbook) is used.


Missing Fields

If the form sends fields that are not mapped:

  • They are recorded in the "Missing fields" list
  • You can review them to add new mappings
  • Serves as an audit of uncaptured data

Existing Contacts

If the lead already exists (same email or phone):

  • Their data is updated
  • The form submission is recorded in the history
  • The previous user assignment is respected

Conclusion

The Web Snippet allows you to:

  • Capture leads from any web form
  • Map fields flexibly
  • Capture tracking data automatically
  • Assign leads to Sales Brains (Playbooks) based on the form

Relevant Scenarios

  • Landing pages: Capture forms connected to Vixiees
  • Multiple websites: One snippet for several pages
  • Campaign tracking: UTMs captured automatically

Was this article helpful?

Related Articles