Setting Up Google Analytics Conversion Pixel Webhook
Send call conversions to a GA4 property server to server through the Measurement Protocol, so calls show up alongside your web analytics.
Updated 3 min read
Browse the knowledge base
On this page
Overview#
The Google Analytics template sends call conversions to a GA4 property server to server through the GA4 Measurement Protocol, so calls appear alongside web analytics.
This is an integration webhook: built under Integrations > Webhooks and attached to campaigns. It is separate from the Google Ads platform integration under Integrations > Platforms, which uploads conversions to Google Ads.
Prerequisites#
- A GA4 property and web data stream.
- A Measurement Protocol API secret for that stream.
- The Measurement ID (format
G-XXXXXXXXXX).
Step 1: Create the API secret in GA4#
- In GA4, go to Admin > Data Streams and select the web stream.
- Open Measurement Protocol API secrets and click Create.
- Name it and copy the secret.
Step 2: Create the webhook#

- In CallGrid, go to Integrations > Webhooks and click New Webhook.
- Name, for example
GA4 - Billable Calls. - Event: pick the moment that counts as a conversion for you:
- Call Billable: the call met the buyer's billable rule.
- Call Converted: the call was marked converted (for example by a postback).
- Call Paid: the call became payable to the source.
- Template Mode: Conversion Pixel, then choose Google Analytics.
- Enter the API Secret and Measurement ID in the template fields.
- Keep Timeout short (the default is 5 seconds).
- Save Webhook.
Step 3: Attach it to campaigns#
Open each campaign, General > Webhooks, and add the webhook. It does not fire until attached.
What the template sends#

The template sends a POST to https://www.google-analytics.com/mp/collect?api_secret=<API Secret>&measurement_id=<Measurement ID> with one GA4 purchase event:
Field | Value sent |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
The template sends the visitor IP as client_id, so the events are not joined to the visitor's GA session. To join them, capture the GA client id on your page into a custom tag and replace [[tag:VisitorIpAddress]] with that tag, for example [[tag:GaClientId]]. Tag names are case sensitive.
Revenue sent to GA is visible to anyone with access to the GA property. If a vendor or client can see the property, consider sending payout or a fixed value instead of revenue.
Firing only for some calls#

Restrict which calls send the event with tag filters (for example BuyerName, CampaignName, InboundStateCode), combining rules with AND or OR. Set them in the webhook's Tag Routing section with Add Filter. Alternatively attach the webhook only to the campaigns that should report to this property.
Testing#

- In the request editor's Webhook Testing section, fill in the Test Variables and click Run Webhook.
- In GA4 open Realtime and confirm the event arrived. Standard reports can take 24 to 48 hours.
- Place a real test call that meets the chosen event and confirm it appears.
Troubleshooting#
Problem | Check |
|---|---|
Nothing in GA4 | Webhook attached on the campaign? Event actually reached (for example the call became billable)? |
GA4 rejects or ignores the hit | API secret active; Measurement ID format ( |
Events not joined to web sessions | The template sends the visitor IP as |
Duplicate conversions | Two webhooks on the same campaign, or both Billable and Converted events used |
Value shows 0 | Revenue not set at the chosen event; use a later event or a fixed value |
Best practices#
- Pick one conversion event per property and document it.
- Rotate the API secret periodically and update the webhook.
- Use Google Ads Platforms for ad bidding optimization; use this webhook for analytics.
Do it with AI#
Ask Griddy, Claude or ChatGPT. Try: "Which of my campaigns send conversions to Google Analytics, and on which event?" Claude and ChatGPT need the CallGrid connector turned on (setup guides for Claude and ChatGPT).
The connector is read only. It looks things up and reads your data. You make the changes in CallGrid.
Was this article helpful?
Related articles
- Setting Up Meta Pixel Conversion WebhookSend call conversions to Meta through the Conversions API, server to server, so Meta can attribute calls to ads without relying on the browser pixel.
- Setting Up CAKE Conversion Pixel WebhookSend a conversion to CAKE when a CallGrid call converts, so CAKE can attribute the call to the right offer and affiliate and pay commissions.
- CallGrid MCP: Connect to ChatGPTAsk ChatGPT about your CallGrid account in plain English. Connect the CallGrid app once, then pull campaigns, buyers, numbers and more.