Skip to content

Capture Google Analytics Data in FormAssembly

FormAssembly collects the name, email and phone number of each lead. It does not, by itself, record which marketing channel brought that person to your site. This guide shows how to close that gap: create the right hidden fields, let an attribution snippet fill them, and use the resulting values in FormAssembly responses, your CRM and your reports.

Why form submissions need source data

Google Analytics can tell you that visitors arrived from paid search, paid social or organic search. It cannot tell you which of those channels produced a particular lead unless the source information travels with the form submission. Sending channel and landing-page values into your CRM or spreadsheet lets you connect marketing activity to leads, opportunities, customers and revenue rather than stopping at traffic counts.

How the attribution snippet works

A small script placed on the website identifies how each visitor arrived and groups the visit into a channel such as Paid Search, Paid Social or Organic Search. When that visitor submits a FormAssembly form, the script writes the values into hidden fields, and FormAssembly stores them next to the visible answers. The values can then be viewed in the responses area, exported to a spreadsheet or data warehouse, or passed to a CRM.

Step 1: Create the hidden fields

Hidden fields sit on the form but are not shown to visitors, so adding them does not change the form's appearance. Create these six fields in FormAssembly: Channel, Channel Drilldown 1, Channel Drilldown 2, Channel Drilldown 3, Landing Page and Landing Page Group. The exact field names matter because the snippet looks for them when it fills in values. For field-by-field instructions, see the FormAssembly hidden-fields help article linked from the source registry.

Field map: what each hidden field answers

Use this map when deciding which field to report on. Channel answers the broad question of how the lead arrived. The three drilldowns narrow that answer to platform, campaign and ad or keyword level. Landing Page records the first page the visitor saw, and Landing Page Group rolls that page up to a section such as /blog.

Step 2: Let the snippet fill the fields

Once the fields exist, the snippet begins tracking arrivals and writing values into them at submission time. The values depend on the UTM parameters attached to the visitor's first touch. A paid Google Ads click, for example, might produce Channel = Paid Search, Channel Drilldown 1 = Google, Channel Drilldown 2 = Brand Campaign and Channel Drilldown 3 = FormAssembly. The same submission would also record the initial landing page, such as www.formassembly.com/blog/best-form-builder, and the landing page group, such as /blog.

Step 3: Confirm the data lands in FormAssembly

On submission, FormAssembly stores the hidden-field values together with the lead's name, email and phone number. Check the responses area to confirm that the fields are populated. From there, FormAssembly integrations or a connector such as Zapier can forward the values to Salesforce, Pipedrive, Zoho CRM, Microsoft Dynamics or another destination.

Step 4: Report on what is working

Source data is only useful if it changes a decision. Rather than listing report types, work backwards from the question you need to answer. If the question is where volume comes from, group monthly lead counts by Channel; a mismatch between the channel producing most leads and the channel receiving most budget is a signal to rebalance. If the question is which paid campaigns create real pipeline, count sales opportunities by Channel Drilldown 2 for paid search leads, so campaigns that generate leads but no opportunities are visible next to those that do. If the question is which placement deserves more spend, count new customers by Channel Drilldown 1 for paid social leads, which separates the networks a single ad platform may run across. In each case the drilldown level you group by should match the decision you are making, not the level that happens to be easiest to chart.

Pre-flight checklist

Before relying on the data, confirm the following. All six hidden fields exist with the exact names above. The snippet is present on every page that hosts a form. A test submission from a tagged URL shows values in the responses area. The same test submission from an untagged URL shows a sensible default rather than blanks. Your CRM mapping uses the same field names so values are not dropped in transit. If a field is empty, first check whether the field name matches exactly; if all fields are empty, check whether the snippet is loading on the page.

Diagnosing empty fields

Empty values usually fall into one of three patterns, and the pattern tells you where to look. If every hidden field is blank on every submission, the snippet is probably not loading on the page that hosts the form, so check the script placement first. If every field is blank only on some pages, compare those pages against ones that work and look for a missing script include. If one field is blank while the others are populated, the field name on the form most likely does not match the expected name exactly, since the snippet fills fields by name. A submission from a direct visit with no source information may also produce default or blank values, which is expected rather than a fault.

Worked example: two visitors, two channels

Imagine a visitor clicks a Facebook ad for a free trial and lands on a blog post. At submission, the hidden fields might read Channel = Paid Social, Channel Drilldown 1 = Facebook, Channel Drilldown 2 = Brand Campaign and Channel Drilldown 3 = Free Trial ad. A second visitor arrives from a Google search and submits the same form; the fields might read Channel = Organic Search, Channel Drilldown 1 = Google, Channel Drilldown 2 = www.google.com and Channel Drilldown 3 = FormAssembly, or the keyword used if it is available. Both submissions also carry the landing page and landing page group. Grouping by Channel now separates the two leads cleanly, and drilling into Channel Drilldown 1 separates the platforms.

Frequently asked questions

Do hidden fields change how my FormAssembly form looks?

No. Hidden fields are part of the form but are not displayed to visitors, so the visible layout stays the same.

What is the difference between Channel and Channel Drilldown?

Channel is the broad group, such as Paid Search or Organic Search. The three drilldowns add detail in layers, for example the platform, then the campaign, then the ad or keyword.

Where can I see the captured values?

They appear in the FormAssembly responses area alongside the lead's other answers, and they can also be forwarded to a CRM or spreadsheet through FormAssembly integrations or a connector such as Zapier.

Why are my hidden fields empty on some submissions?

Check two things first. Confirm the field names match the six names exactly, because a mismatch prevents the snippet from filling them. Then confirm the snippet is loading on the page where the form appears. A submission from a direct visit may also produce default or blank values if no source information is available.