Skip to content

Capture the GCLID in Salesforce Account Engagement and Feed Google Ads Offline Conversions

If you run Google Ads for lead generation, the click that started a relationship is easy to lose once the lead becomes a prospect in your CRM. This guide shows how to keep the Google Click ID (GCLID) attached to each new prospect in Salesforce Account Engagement (formerly Pardot), carry it through to the Salesforce Lead or Contact, and send it back to Google Ads as an offline conversion so bidding can learn from real outcomes.

What you are actually building

The goal is a chain of custody for one value: the GCLID. It starts in the ad click URL, gets stored in the visitor's browser, is written into a hidden form field on submit, lands on the Account Engagement prospect record, syncs to the matching Lead or Contact in Salesforce, and is available when an Opportunity is created. From there a connector such as Zapier can pass it to Google Ads as an offline conversion.

Two failure points cause most missing GCLIDs:

  • URL-only capture. If your form tool only reads the URL at submit time, a visitor who clicks the ad, browses to another page, and then fills in a form will have no GCLID in the URL. The value is lost.
  • No hidden field. If the form has nowhere to write the GCLID, the value never reaches Account Engagement even when it was captured correctly in the browser.

A browser-stored approach solves the first problem; a correctly configured hidden field solves the second.

Step 1 — Install the capture script and add a GCLID hidden field

Sign up for the capture tool and place its snippet on your website. Installation differs by platform (WordPress, Webflow, Squarespace, and others), and Google Tag Manager is an alternative delivery route.

Then add a hidden field named for the GCLID to every form that should record it:

  • Account Engagement native forms: create a custom prospect field for the GCLID and add it to the form as a hidden field.
  • Third-party form tools: add the hidden field in that tool instead.

Either way, the hidden field is the destination the script writes into when a visitor submits. Detailed setup instructions live on the vendor's help site.

Step 2 — How the GCLID is stored and written

When a visitor arrives from a Google Ad, the script reads the GCLID from the URL and saves it in the browser. That persistence matters: the visitor can move through several pages, leave the site, and return later, and the GCLID is still available. On form submission, the saved value is written into the hidden field you configured.

Step 3 — Getting the GCLID onto the Salesforce record

On submit, the GCLID is captured alongside the lead's name, email, phone number, and other details.

  • Native Account Engagement forms: the GCLID is stored on the prospect record and syncs automatically to the corresponding Lead or Contact in Salesforce.
  • Third-party forms (Gravity Forms, Typeform, Jotform, and similar): use the tool's built-in integration or a connector such as Zapier to send the GCLID to Account Engagement with the rest of the lead data.

Once synced, the GCLID is available when an Opportunity is created — the point where you can trigger the hand-off back to Google Ads.

Step 4 — Create the offline conversion action in Google Ads

In Google Ads, open Goals in the left sidebar, go to Conversions, and create a new conversion. Choose Offline Conversion as the type. On the final screen asking for a data source, select the option to add the data source later — you will connect it through your automation tool.

Choosing the conversion point: a decision checklist

Before wiring the send, decide which sales event counts as the conversion. This choice affects how much signal Google's bidding algorithms receive.

Use this checklist:

  1. How many deals do you close per month? Google's Smart Bidding strategies (Maximise Conversions, Maximise Conversion Value, Target CPA) are described as needing around 50 conversions per month to perform effectively. Treat that figure as a dated reference and check current guidance.
  2. If you close fewer than 50 deals a month, consider tracking an earlier pipeline event — for example, when an Opportunity is created in Salesforce — so bidding has enough data to optimise.
  3. If you close well above that threshold, a later event such as Closed Won may give a truer picture of value.
  4. Match the trigger to the event you chose. The automation trigger and the Google Ads conversion action must refer to the same stage, or reporting and bidding will diverge.

Step 5 — Send the GCLID back through Zapier

Create a new Zap. Set the trigger to the conversion event you selected — for example, Opportunity created in Salesforce. Choose Google Ads as the action app and Send Offline Conversion as the event. The final mapping step pairs the GCLID from Salesforce with the GCLID field in Google Ads.

Before increasing spend, test that a conversion actually arrives in Google Ads. A worked example of the full loop is covered in the linked guide on sending offline conversions from a CRM to Google Ads.

Why browser-side storage beats URL-only capture

Some form tools and URL-parameter methods only read what is in the URL at the moment of submission. If a visitor clicks your ad, lands on the homepage, then navigates to a contact page to fill in a form, the GCLID is gone from the URL and will not be captured.

A browser-stored approach captures the GCLID the instant the visitor arrives, so multi-page journeys and return visits still carry the value through to the form. That is the difference between a partial picture of paid search performance and a complete one.

Beyond the GCLID: UTM and organic attribution

The same hidden-field mechanism can carry UTM parameters, giving each lead a channel and drilldown trail. For an accounting firm whose prospect clicked a paid search ad, the captured values might look like this:

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

Visitors from organic channels can be classified too — Organic Search, Organic Social, Referral, Direct Traffic, and others. A lead who arrived via a regular Google search might record:

  • Channel = Organic Search
  • Channel Drilldown 1 = Google
  • Channel Drilldown 2 = www.google.com
  • Channel Drilldown 3 = Best Tax Accountant Near Me (when the search term is available)

These fields let you compare paid and organic lead quality in the same CRM view.

Field and control map

Use this map to check each stage of the chain:

Field and control map
StageWhere the value livesWhat to verify
Ad clickGCLID in the landing page URLAds are tagged so the parameter is present
BrowserStored GCLIDScript loads on every page, not just the landing page
FormHidden GCLID fieldField exists on every relevant form
Account EngagementProspect record fieldCustom prospect field is created and mapped
SalesforceLead or Contact recordConnector sync is active
OpportunitySalesforce recordGCLID is available at the chosen trigger stage
Google AdsOffline conversionConversion action exists and GCLID is mapped in the automation

Frequently asked questions

What is the difference between capturing the GCLID in the URL and storing it in the browser?

URL-only capture reads the parameter at the moment the form is submitted. If the visitor navigated away from the landing page first, the GCLID is no longer in the URL and is lost. Browser storage keeps the value from the first arrival, so it survives page changes and return visits and is written into the hidden field on submit.

Do I need a custom field in Account Engagement for the GCLID?

For native Account Engagement forms, yes — create a custom prospect field for the GCLID and add it to the form as a hidden field. The GCLID is then stored on the prospect record and syncs to the matching Lead or Contact in Salesforce.

Should I send the conversion when a deal is won or when the Opportunity is created?

It depends on volume. Google's Smart Bidding strategies are described as needing around 50 conversions per month to perform effectively. If you close fewer than 50 deals a month, tracking an earlier event such as Opportunity creation gives bidding more data. If you close well above that, a later event can better reflect deal value. Verify current thresholds before deciding.

Can I use a third-party form tool instead of Account Engagement native forms?

Yes. Add the GCLID hidden field in the third-party tool and use its built-in integration or a connector such as Zapier to send the GCLID to Account Engagement along with the rest of the lead's details.

How do I know the offline conversion is actually reaching Google Ads?

After the Zap is configured, run a test conversion through the full chain and confirm it appears in Google Ads before increasing spend. The linked guide on sending offline conversions from a CRM covers how to test the setup.