How to install heeet Javascript

Heeet's Javascript SDK lets you easily track website visits and form submissions. Follow these steps to get started:

Once the SDK is installed, you’ll get better channel attribution if your outbound links are consistently tagged—use the UTM builder to standardize your UTMs.

1. Copy and Paste the Code Snippet

Add the following code inside your website's <head> tag:

<script src="https://javascript.heeet.io?v=2"><\/script>
<script>
Heeet.trackVisit();
Heeet.trackForm("putyourformselectorhere", {
 data: "putyourinputnamehere"
});
<\/script>

2. SDK Methods

Method Parameters Description
Heeet.trackVisit() None Tracks a page visit and associates it with the current visitor journey.
Heeet.trackForm("formSelector", {  data: "putyourinputnamehere"}); formSelector: CSS selector for the form element
options.heeetId: Heeet ID of the lead (optional if using Heeet for Salesforce or HubSpot)
options.data: Target field where tracking data will be injected
Injects Heeet tracking data into a form submission to link marketing activity with CRM records.
Heeet.trackGTMEvents(["eventName"]) eventName: Name of the GTM Event
Catch Google Tag Manager Event
Heeet.trackGAEvents(["eventName"]) eventName: Name of the Google Analytics Event
Catch Google Analytics Event


Implementation Example

Here's a complete example of how to implement Heeet on your website:

<!DOCTYPE html>
<html>
<head>
<title>Your Website</title>
</head>
<body>
<!-- Your website content -->

<!-- Contact Form -->
<form id="contact-form">
<input type="text" name="name" placeholder="Name" required>
<input type="email" name="email" placeholder="Email" required>
<input type="hidden" name="Heeet__Data__c" id="heeet-data">
<input type="hidden" name="Heeet__Id__c" id="heeet-id">
<button type="submit">Submit</button>
</form>

<!-- Heeet Script -->
<script>
   // Initialize Heeet tracking
   Heeet.trackVisit();
   Heeet.trackForm("#contact-form", {
       heeetId: ".heeet-id",
       data: ".heeet-data"
   });
</script>
</body>
</html>

Get Started: How to install heeet Javascript

Follow this guide to set up Javascript SDK Installation in Javascript with Heeet and keep your data in sync automatically.

Book a demo