> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cometly.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Zoho Forms form tracking

> Set up Zoho Forms form tracking in Cometly: pass the fingerprint and Comet Token into your embedded form so each entry is tied to its ad.

Zoho Forms form tracking passes the visitor's Cometly fingerprint and Comet Token into your embedded Zoho form. Both are identifiers the Cometly pixel (the tracking script you install on your site) gives each visitor, and they link a form entry to that visitor's tracked session.

This matters because an embedded Zoho form loads inside an iframe, so an entry does not carry the visitor's session on its own. Once both values travel with each entry, the entries you send to Cometly as events (tracked actions such as a lead) can be attributed to the right source, and you can see which ad or channel produced each lead.

## Before you start

> [!NOTE]
>
> This setup is for a **Zoho form embedded on your page as an iframe**. Follow the steps in order: each one builds on the one before it.

> [!WARNING]
>
> The Cometly Pixel Helper and the in-app form tracking test do not work on an embedded Zoho form. Instead, step 5 shows how to check that your Zoho entries carry the values, and the [Zoho integration guide](https://docs.cometly.com/integrations/platforms/zoho.md) covers testing the event Cometly receives.

## Step 1: Add the Cometly pixel before the closing head tag

Install the Cometly pixel before the closing `</head>` tag on every page of your funnel or website.

[Install the Cometly pixel](https://docs.cometly.com/getting-started/install-pixel.md)

## Step 2: Add custom code to the page that holds the Zoho form

On the web page where your Zoho form is embedded, add the following code before the closing `</body>` tag. It adds the fingerprint and Comet Token to the form's iframe URL, so the hidden fields you create in the next steps are filled in automatically.

[Video: step 2, add custom code before the closing body tag on the page with the Zoho form](https://www.loom.com/embed/6d29012c1f4e4ca6bf1444ccc018f719)

```html theme={null}
<script>
function waitForCometlyAndExecute(callback, maxAttempts = 10, interval = 500, delay = 2000) {
    setTimeout(() => {
        let attempts = 0;

        const checkAndExecute = () => {
            if (typeof cometFingerprint === "function" && typeof cometToken === "function") {
                callback();
            } else if (attempts < maxAttempts) {
                attempts++;
                setTimeout(checkAndExecute, interval);
            } else {
                console.error("Cometly functions not available after multiple attempts.");
            }
        };

        checkAndExecute();
    }, delay);
}

waitForCometlyAndExecute(() => {
    cometFingerprint().then(function(fingerprint) {
        var cometTokenValue = cometToken();

        var iframe = document.querySelector("iframe[src*='zohopublic.com']");
        if (iframe) {
            var originalSrc = iframe.getAttribute('src');
            var delimiter = originalSrc.includes('?') ? '&' : '?';
            var newSrc = `${originalSrc}${delimiter}fingerprint=${encodeURIComponent(fingerprint)}&comet_token=${encodeURIComponent(cometTokenValue)}`;

            iframe.setAttribute('src', newSrc);
        } else {
            console.error("Iframe not found.");
        }
    }).catch(function(error) {
        console.error("Error obtaining Cometly fingerprint:", error);
    });
});
</script>
```

## Step 3: Add hidden form fields to your Zoho form

For Cometly to attribute the Zoho form submission to the correct source, create two hidden fields on your form.

[Video: step 3, add hidden form fields to your Zoho form](https://www.loom.com/embed/58cda85984c64bc1b3c5bbe1c8f4b276)

**1. Add two Multi Line fields**

Add two **Multi Line** fields to your Zoho form.

![Zoho Forms builder with the Multi Line field type and two Multi Line fields added to the form](https://mintcdn.com/cometly/4NU5YV9iL1PADmGE/images/integrations/forms/zoho-forms/01.webp?fit=max\&auto=format\&n=4NU5YV9iL1PADmGE\&q=85\&s=19ed4c97dd8ee64aef480dc11edf3916)

**2. Open the first field's properties**

Hover over the first Multi Line field and click **Properties**.

![Zoho Forms builder with an arrow on the Properties icon next to the first Multi Line field](https://mintcdn.com/cometly/4NU5YV9iL1PADmGE/images/integrations/forms/zoho-forms/02.webp?fit=max\&auto=format\&n=4NU5YV9iL1PADmGE\&q=85\&s=ab6783d461ca393789b55197885d81cb)

**3. Rename the first field to fingerprint and hide it**

Change the field label of the first Multi Line field to `fingerprint`.

* Select **Hide Field Label**.
* Select **Hide Field** under the Visibility section.
* Click **Save**.

<video autoPlay muted loop playsInline src="https://mintcdn.com/cometly/4NU5YV9iL1PADmGE/images/integrations/forms/zoho-forms/03.mp4?fit=max&auto=format&n=4NU5YV9iL1PADmGE&q=85&s=dba88abe77f4823fd90be0e7eaf1b78a" aria-label="Zoho Forms field Properties panel where the field label is renamed to fingerprint and the field is hidden" />

**4. Rename the second field to comet\_token and hide it**

Change the field label of the second Multi Line field to `comet_token`.

* Select **Hide Field Label**.
* Select **Hide Field** under the Visibility section.
* Click **Save**.

<video autoPlay muted loop playsInline src="https://mintcdn.com/cometly/4NU5YV9iL1PADmGE/images/integrations/forms/zoho-forms/04.mp4?fit=max&auto=format&n=4NU5YV9iL1PADmGE&q=85&s=cb1d6253bf5afe5976dc81fefe1b4d67" aria-label="Zoho Forms builder with the first field hidden, before the second Multi Line field is renamed to comet_token" />

## Step 4: Set up Zoho Forms to prefill the hidden fields

[Video: step 4, set up Zoho Forms to prefill the hidden field values](https://www.loom.com/embed/f09d1a3b09eb4a2a8fb7146626c1000b)

The script in step 2 appends the fingerprint and Comet Token to the iframe URL. Set up your Zoho form so Zoho prefills the hidden fields with those values.

1. Edit your form and click **Settings**.
2. Under **General** on the left panel, click **Field Alias - Prefill URL**.
3. Click **Configure Now**.

![Zoho Forms Settings with Field Alias - Prefill URL selected and the Configure Now button](https://mintcdn.com/cometly/4NU5YV9iL1PADmGE/images/integrations/forms/zoho-forms/05.webp?fit=max\&auto=format\&n=4NU5YV9iL1PADmGE\&q=85\&s=424f63a0433255c4516ea2c08778d914)

Then add an alias for each hidden field:

1. In the **Field Label** selection, choose `fingerprint`, and in the **Field Alias** box type `fingerprint`.
2. Click the **+** sign.
3. In the second **Field Label** selection, choose `comet_token`, and in the **Field Alias** box type `comet_token`.
4. Click **Save**.

<video autoPlay muted loop playsInline src="https://mintcdn.com/cometly/4NU5YV9iL1PADmGE/images/integrations/forms/zoho-forms/06.mp4?fit=max&auto=format&n=4NU5YV9iL1PADmGE&q=85&s=79a0584850599e184510da29ec5c0e74" aria-label="Zoho Forms Field Alias - Prefill URL screen where aliases are added for fingerprint and comet_token" />

## Step 5: Test that your entries include fingerprint and comet\_token

Open the page that holds your embedded Zoho form and submit a test entry. Then open that entry in Zoho Forms and check that the fingerprint and Comet Token are included. Make sure both values are there before you continue to the next step. The video below shows the test.

[Video: step 5, test your form to make sure fingerprint and comet\_token are on your entries](https://www.loom.com/embed/8cea7b1b262f41c2b9ed290de449a54a)

## Step 6: Send event data from Zoho Forms or Zoho CRM

There are two ways to send event data from Zoho to Cometly. See the section of the Zoho integration guide that matches how you want to send events:

[Set up the Zoho integration (for Zoho Forms or Zoho CRM)](https://docs.cometly.com/integrations/platforms/zoho.md)

## Check it worked

Submit a test entry on the embedded form on your page. The entry in Zoho Forms now has a value in both the `fingerprint` and `comet_token` fields. Once you have also set up the Zoho Forms webhook in step 6, the event you chose appears in Cometly under **Events Manager**, on the **Events Log** tab.

## Frequently asked questions

### Why are fingerprint and comet\_token empty in my Zoho Forms entries?

The code can only add the values when the Cometly pixel is installed on the page that holds the form, so check that first. Then check that the code from step 2 is on that same page, and that the field labels and field aliases are exactly `fingerprint` and `comet_token`. The code adds the values about two seconds after the page loads, and only on the page it is installed on, so an entry submitted through a direct link to the form will not have them.

### Does Zoho Forms form tracking send my entries to Cometly?

No. The hidden fields and the code only attach the fingerprint and Comet Token to each entry. To get the entry into Cometly as an event, you still add the Cometly webhook to your form in Zoho, as covered in step 6.

### Do I need both the fingerprint and comet\_token hidden fields?

Yes, create both. The Zoho Forms webhook you set up in step 6 sends both fields to Cometly, and together they link the entry to the visitor's session on your site. That link is how Cometly attributes the entry to an ad or channel.

## Next steps

* [Send Zoho Forms entries to Cometly with the Zoho integration](https://docs.cometly.com/integrations/platforms/zoho.md)
* [Use the Events Log to check incoming events](https://docs.cometly.com/support/troubleshooting/general/event-log.md)
* [Form tracking for third-party embedded forms](https://docs.cometly.com/guides/form-tracking/third-party-forms.md)
* [Install the Cometly pixel](https://docs.cometly.com/getting-started/install-pixel.md)
* [Learn how events work in Cometly](https://docs.cometly.com/guides/events/how-events-work.md)

Still have questions or need a hand? We're happy to help. Reach our team at [support@cometly.com](mailto:support@cometly.com).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.