Overview
PostMessage Tracking allows you to track the actions happening within your form and share them with the website via a post message. This enables any web analytics service configured on your website to receive these events and build conversions, creating a unified tracking approach for both your form and website, even when hosted on a different domain.
Pre-requisites
- Google Tag Manager (GTM) or any web analytics service must be properly configured on the website to ensure that the events are successfully captured.
Google Tag Manager (GTM) and PostMessage Tracking operate independently. Therefore, configuring both simultaneously for the same form might result in duplicate event captures.
Configuring PostMessage Tracking
- In your form builder, navigate to the Share tab > Google Tag Manager & Custom Tracking.
Navigate to
PostMessage Tracking and click
Configure.

- Enter an alternate name for your form in Form Alias to identify it on your website.
Under Configure Events, select the form events for which you want to push the event details to the website where your form is embedded.
Form View: Pushes an event when a respondent views your form.
Page View: For multiple-page forms, you can push an event when a respondent visits the selected pages. Enter an alias name for the selected pages to identify them in the website.
Onclick Fields: Pushes an event when a respondent clicks the selected fields in the form. Enter an alias name for the selected fields to identify them in the website.
Review Form: Pushes an event when a respondent reviews the form.
Save Form: Pushes an event when a respondent saves your form.
Submit Form: Pushes an event when a respondent submits your form. To push data from your form to an external website, enable
Configure Data Push and then map the fields you want to send.
- View the list of variables that will be pushed with each event by hovering over the event and clicking Variables.
- Click Save.
- After saving, a popup with the PostMessage Tracking Code will be displayed. Copy this code, embed it in your website's header, and publish your website.
Within the code, any additional functionality should be implemented by invoking a dedicated function within the appropriate event listener. Avoid placing the entire custom logic directly inside the event listener. This approach ensures that any errors in your custom code will not interfere with the stable operation of the existing implementation.
Note: PostMessage Tracking is not supported if the form is embedded on your website using the HTML/CSS embed option.
Data Push Configuration
To push data from your form to an external website, enable Configure Website Data Push under Submit event and then map the fields you want to send.
View the list of variables that will be pushed by hovering over the Submit event and clicking Variables.
Note: If your form is HIPAA-enabled and you have marked certain fields as HIPAA-compliant, then the ePHI data will not be pushed to external sources unless you explicitly choose to send that data in your form settings.
Capturing Form Data via Data Layer Variable in GTM
To fetch the values entered in the form that are sent via Data Push, you must create a DataLayer Variable within Google Tag Manager(GTM). This variable acts as a pointer/key to fetch specific records stored within the zf_data JSON that your from pushes to the data layer.
For example, to fetch the first name entered in the form, set the Data Layer Variable Name to zf_data.zf_name_first.
Here zf_data denotes to JSON which contains all the pushed form values. zf_name_first is the variable that holds the first name value.
This ensures that GTM successfully retrieves the respondent's first name. You can use the same procedure to fetch any other mapped values.
PostMessage Tracking with Google Tag Manager (GTM)
If your form is configured with PostMessage Tracking and your website uses GTM, follow these steps
- Embed Tracking Code
Place the PostMessage Tracking Code in your website's header section. This will capture the form events on your website. GTM Configuration
In your Google Tag Manager, ensure you have set up the following to push the captured events to Google Analytics.
PostMessage Tracking with Other Web Analytics Services
If your form is configured with PostMessage Tracking and your website uses web analytics services other than GTM then
- Embed Tracking Code
Place the PostMessage Tracking Code in your website's header section. This will capture the form events on your website. Customize Embed Tracking Code
To push the captured events to your specific web analytics service, customize the PostMessage Tracking Code as required.

Within the code, any additional functionality should be implemented by invoking a dedicated function within the appropriate event listener. Avoid placing the entire custom logic directly inside the event listener. This approach ensures that any errors in your custom code will not interfere with the stable operation of the existing implementation.
- Configure Analytics Service
Properly configure your specific web analytics service to receive the events.
Benefits of Using PostMessage Tracking
- Unified Analytics: Consolidates data from your form and your website into a single analytics platform.
- Cross-Domain Tracking: Track user behaviour even when your form is hosted on a different domain than your website.
- Consent-Driven Tracking: Event data is only triggered to web analytics services upon user acceptance of consent. With PostMessage Tracking, once consent is given on the website, event data is immediately triggered for conversions, contrasting with Zoho Forms GTM configuration.
- Payment Forms: Post Message Tracking can be configured for payment forms.
- Non-Google Tags Support: Trigger events for non-google tags like TikTok, Meta Pixel, and Pinterest are supported as we are sharing the events with your website.
Note:
- If you configure a custom domain after setting up PostMessage Tracking, you must retrieve and re-embed the code in your website's header.
- Event capture occurs only when the form is accessed while embedded in a website, not when accessed directly via its URL.
- Your website is responsible for obtaining user consent for data transfer to analytics, as forms transmit data only to your website, it is then forwards it to analytics services via your website.