Tracking Setup

This guide explains how Google click IDs and UTM parameters are captured from website visitors and stored on CRM leads, and how to configure your marketing URLs for proper attribution tracking.

Important

Attribution tracking requires that your website or landing page is configured to capture URL parameters and pass them to Progrid CRM when creating leads. This module provides the CRM-side storage and display; the website-side capture depends on your web form implementation.

How Click IDs Get Captured

When a visitor clicks a Google Ad, Google automatically appends a click identifier to the destination URL. The capture flow works as follows:

  1. Google Ads appends the click ID to your URL:

    https://yoursite.com/contact?gclid=EAIaIQobChMI_example_click_id
    
  2. Your website captures the gclid parameter from the URL (typically via JavaScript or server-side form processing)

  3. Form submission sends the captured click ID along with the lead data to Progrid CRM (via API, webhook, or web form integration)

  4. Progrid CRM stores the click ID in the x_gclid field on the new lead record

The same process applies to gbraid and wbraid parameters.

Configuring Google Ads URLs

Google Ads automatically appends gclid parameters when auto-tagging is enabled. To verify:

  1. Sign in to your Google Ads account

  2. Navigate to Settings ‣ Account Settings

  3. Expand the Auto-tagging section

  4. Verify Tag the URL that people click through from my ad is checked

Note

Auto-tagging is enabled by default in Google Ads. If you use manual tagging for UTM parameters, you can use both simultaneously – Google will append gclid in addition to your manual UTM tags.

UTM Parameter Setup

Building Tracked URLs

Add UTM parameters to your marketing URLs to track campaign details. Use Google’s Campaign URL Builder or construct them manually:

https://yoursite.com/contact?utm_source=google&utm_medium=cpc&utm_campaign=spring_roofing&utm_term=roof+repair&utm_content=ad_v2

Required parameters:

  • utm_source – Identifies the traffic source (e.g., google, facebook, newsletter)

  • utm_medium – Identifies the marketing medium (e.g., cpc, email, social, organic)

  • utm_campaign – Identifies the specific campaign name

Optional parameters:

  • utm_term – Identifies paid search keywords

  • utm_content – Differentiates ad variations or links within the same campaign (useful for A/B testing)

Combining Click IDs with UTM Parameters

When using Google Ads with auto-tagging enabled, the final URL will contain both your manual UTM parameters and the auto-appended click ID:

https://yoursite.com/contact?utm_source=google&utm_medium=cpc&utm_campaign=spring_roofing&gclid=EAIaIQobChMI_example

This gives you the best of both worlds: detailed campaign tracking via UTM and individual click tracking via the click ID.

Website Integration

Your website must be configured to capture these URL parameters and include them when submitting lead data to Progrid CRM. The specific implementation depends on your website platform:

Web Form Integration

If your website uses Progrid website forms (via the website_crm module), UTM parameters are captured automatically. Click ID capture may require additional JavaScript:

// Example: Capture gclid from URL and add to hidden form field
const urlParams = new URLSearchParams(window.location.search);
const gclid = urlParams.get('gclid');
const gbraid = urlParams.get('gbraid');
const wbraid = urlParams.get('wbraid');

if (gclid) {
    document.querySelector('input[name="x_gclid"]').value = gclid;
}
if (gbraid) {
    document.querySelector('input[name="x_gbraid"]').value = gbraid;
}
if (wbraid) {
    document.querySelector('input[name="x_wbraid"]').value = wbraid;
}

API Integration

If leads are created via the Progrid API (e.g., from a custom landing page or third-party form tool), include the attribution fields in the API call:

{
    "name": "New Lead from Google Ads",
    "contact_name": "Jane Smith",
    "email_from": "jane@example.com",
    "x_gclid": "EAIaIQobChMI_example_click_id",
    "source_id": 1,
    "medium_id": 2,
    "campaign_id": 3
}

Viewing Attribution Data on Leads

Once attribution data is captured, it appears on the CRM lead form:

  1. Open any lead in CRM ‣ Pipeline

  2. Look for the Attribution section on the lead form

  3. The following fields are displayed:

    • Google Click ID (gclid) – The primary Google Ads click ID

    • Google Broad Attribution (gbraid) – iOS broad attribution ID

    • Google Web Attribution (wbraid) – iOS web attribution ID

    • Source – UTM source value

    • Medium – UTM medium value

    • Campaign – UTM campaign value

Note

Attribution fields are read-only on the lead form. They are populated automatically during lead creation and should not be manually edited to preserve data integrity.

Offline Conversion Tracking

One of the most valuable uses of click ID data is uploading offline conversions back to Google Ads. This tells Google which ad clicks led to actual sales, enabling better ad optimization.

Workflow:

  1. Export won opportunities from Progrid CRM with their x_gclid values, conversion dates, and revenue amounts

  2. Format the data according to Google Ads offline conversion import requirements

  3. Upload to Google Ads via Tools & Settings ‣ Conversions ‣ Uploads

  4. Google Ads uses this data to optimize bidding and targeting for future campaigns

Tip

Set up a regular schedule (weekly or monthly) for uploading offline conversions. Consistent uploads give Google Ads more data to optimize your campaigns.

Best Practices

  1. Enable auto-tagging in Google Ads. This ensures every click gets a gclid automatically without manual URL configuration.

  2. Use consistent UTM naming. Standardize your source, medium, and campaign naming conventions across all marketing channels. Use lowercase and hyphens (e.g., google, paid-search, spring-roofing-2024).

  3. Test the full flow. After setting up tracking, click a test ad, submit a form, and verify the attribution data appears on the resulting CRM lead.

  4. Don’t mix tracking methods. Use either auto-tagging (recommended) or manual gclid parameters, not both, to avoid conflicts.

  5. Preserve click IDs. Never manually edit or clear click ID fields on leads. They are needed for offline conversion tracking and attribution analysis.

Next Steps