How to capture the GCLID in Formstack

Learn how to capture the GCLID with every Formstack form submission on your website, so you can send it to your CRM and other tools (and pass it back to Google Ads as an Offline Conversion).

Formstack - GCLID

Google Ads can be a great way to bring in new leads for your business.

But here's the challenge. If you can't tell which of those leads go on to become paying customers, you might be spending your budget on campaigns that generate lots of impressions and clicks but don't actually produce results that matter.

The good news? There's an easy way to fix this.

In this article, we'll show you how to use Attributer to capture the GCLID with every Formstack form submission and pass it straight to your CRM and other tools. We'll also walk you through how to send that data back to Google Ads to track offline conversions, so you can see exactly which campaigns are driving real business.

3 steps for capturing the GCLID in Formstack

Capturing the GCLID with Formstack forms is easy when you use Attributer. Here's how to do it:

1. Install Attributer on your website and add a hidden field

Add Attributer Code to Site Mobile

When you sign up for a free 14 day trial of Attributer, you'll get a small snippet of code to add to your website.

The exact process will vary depending on your website builder (whether it's WordPress, Squarespace, Wix, or something else), but most platforms make it easy to add through their settings area or through Google Tag Manager (and you can find full step by step instructions here).

Once the code is installed, the next step is to add a hidden GCLID field to your Formstack forms. This gives Attributer a place to write the GCLID value, so it's automatically captured every time a visitor submits your form.

2. Attributer writes the GCLID into the hidden field

Data in hidden fields - GCLID

When a visitor clicks on one of your Google Ads and arrives at your website, Attributer grabs the GCLID from the URL and saves it in their browser.

Then when they submit a Formstack form on your site, Attributer automatically populates the hidden field with the GCLID value.

3. GCLID is captured with each form submission

New Form Submission with GCLID

When the form is submitted, the GCLID is captured in Formstack along with all the other information the person entered, like their name, email, phone number, and any other fields on the form.

From there, you can send the GCLID to your CRM using Formstack's built in integrations or through a third party connector like Zapier (which connects Formstack with CRMs like HubSpot, Pipedrive, Salesforce, and others).

How to send the GCLID back to Google Ads and mark it as an offline conversion

Before you can send the GCLID back to Google Ads, you'll first need to create a new conversion action.

To do this, log into your Google Ads account, go to the sidebar, and click on Goals, then Conversions. From there, click the button to create a new conversion and select Offline Conversion as the type.

Offline Conversions Setup

Then, in the final screen when it asks you to add a data source, select the option to ‘Add data source later’.

Offline Conversion Data Source

Now that your conversion action is set up in Google Ads, you can start sending GCLID data back. But first, you need to decide which stage in your sales process you want to count as the conversion.

Many people choose to wait until a deal is fully closed before sending the conversion to Google Ads. That's a reasonable approach, but it can cause issues. Google's smart bidding strategies like Maximise Conversions, Maximise Conversion Value, and Target CPA need around 50 conversions per month to work well. If your business closes fewer than 50 deals in a typical month, you're better off choosing an earlier stage in your pipeline instead (like when a new deal is created) so Google has enough conversion data to optimise effectively.

Once you've decided on your conversion point, go into your Zapier account and create a new Zap. Set the trigger to match the milestone you selected. For example, if you want to send the offline conversion when a deal is created for a contact, choose that event as your trigger.

New Deal to Google Ads

Next, select Google Ads as the Action and then select the ‘Send Offline Conversion’ as the event.

Select Offline Covnersion in Zapier

Finally, you just need to map the GCLID from your CRM (or wherever you are storing it) to the correct field in Zapier.

Select GCLID

That’s it! You have now set up offline conversions in Google Ads. It’s a good idea to test it’s working before piling money into ads, and you can read more about how to do that here.

Why Attributer is the best way to capture the GCLID in Formstack

There are a few different ways to capture the GCLID in Formstack forms, so why choose Attributer over the alternatives?

Here's what sets it apart:

1. Remembers the GCLID as visitors browse your site

Most GCLID capture methods share a common flaw: they only work if the GCLID is still sitting in the URL at the exact moment someone submits a form. In reality, that almost never happens.

Think about how a typical customer journey actually unfolds. Someone clicks your Google Ad and lands on your homepage. They browse around, check out a few pages, and eventually make their way to your Contact Us form to reach out. By that point, the GCLID that was in the URL of their first landing page is long gone.

Attributer handles this differently. The moment a visitor arrives on your site, it saves the GCLID directly to their browser. From there, it doesn't matter how many pages they visit before converting, or even if they leave and come back days later. When they finally submit a form, Attributer pulls that original GCLID from the browser and writes it into the hidden field automatically.

2. Captures UTM parameters as well

Alongside the GCLID, Attributer also captures the UTM parameters from your ad URLs and passes them through with every Formstack form submission.

Here's a practical example of what that looks like. Say you run an accounting firm and someone clicks one of your Google Ads and fills out your contact form. Attributer would capture the following details and write them into the hidden fields:

  • Channel = Paid Search
  • Channel Drilldown 1 = Google
  • Channel Drilldown 2 = Tax Services Campaign
  • Channel Drilldown 3 = Small Business Accountant Melbourne
  • Channel Drilldown 4 = Free Consultation Ad

Once that data lands in your CRM and reporting tools, you stop guessing and start knowing. You can see exactly where each lead came from and which ads are actually generating real leads and customers for your business.

3. Captures information on users from organic channels

Paid campaigns aren't the only thing Attributer tracks. It also captures attribution data for leads who find your site through organic channels like Organic Search, Organic Social, Referral, Direct Traffic, and more.

Sticking with the accounting firm example, if someone found your site by typing a query into Google rather than clicking an ad, Attributer would write something like this into the hidden fields:

  • Channel = Organic Search
  • Channel Drilldown 1 = Google
  • Channel Drilldown 2 = www.google.com
  • Channel Drilldown 3 = Small Business Accountant Melbourne

This means you get a complete picture of where all your leads are coming from, not just the ones clicking on your paid ads.

Wrap Up

Capturing the GCLID in your Formstack forms and passing it back to Google Ads as an offline conversion doesn't have to be complicated. Attributer makes the whole thing straightforward.

It saves the GCLID in the visitor's browser the moment they land on your site and retains it as they browse, or even if they leave and return days later. And when they eventually fill out a form, the GCLID is included with the submission and can be sent to your CRM and other tools.

The best part? It's free to get started, and setup usually takes less than 10 minutes. Kick off your 14-day free trial today and start capturing GCLIDs in your Formstack forms.

Get Started For Free

Start your 14-day free trial of Attributer today!

aaron-beashel

About the Author

Aaron Beashel is the founder of Attributer and has over 15 years of experience in marketing & analytics. He is a recognized expert in the subject and has written articles for leading websites such as Hubspot, Zapier, Search Engine Journal, Buffer, Unbounce & more. Learn more about Aaron here.