Send conversion events to Google Ads

Last updated:

|Edit this page

Send conversion events from PostHog to Google Ads.

Requirements

Using this requires either PostHog Cloud with the data pipelines add-on, or a self-hosted PostHog instance running a recent version of the Docker image.

You'll also need access to the relevant Google Cloud, Google Ads and Google Ads Manager account.

Installation

  1. Apply for a Google Ads developer token using these steps.

  2. Enable the Google Ads API in your Google Cloud settings.

  3. Enable Enhanced conversions under the Goal settings and set the method to Google Ads API.

  4. In PostHog, click the "Data pipeline" tab in the left sidebar.

  5. Click the Destinations tab.

  6. Search for Google Ads Conversions and select the destination.

  7. Connect your Google account at the configuration step.

  8. Fill out your Customer ID.

    Location of the Google Ads Customer ID
  9. Create a conversion action inside Google Ads

    1. You'll need to create a conversion goal under Goals > Conversions > Summary
    2. Click Create conversion action
    3. Select Website
    4. Scan your website
    5. Click Add a conversion action manually and enable Enhanced conversions
    6. Click save and continue
    7. Click see the event snippet
    8. It should show something like gtag('event', 'conversion', {'send_to': 'AW-XXXXXXXXXXX/XXXXXXXXXXXXXXXXXX'})
    9. In this case, the Conversion action ID is going to be the send_to value before the forward slash like AW-XXXXXXXXXXXSteps to create a conversion action inside Google Ads
  10. Press Create & Enable and watch your conversions get sent to Google Ads!

Configuration

OptionDescription
Google Ads account
Type: integration
Required: True
Developer token
Type: string
Required: True
This should be a 22-character long alphanumeric string. Check out this page on how to obtain such a token: https://developers.google.com/google-ads/api/docs/get-started/dev-token
Customer ID
Type: string
Required: True
ID of your Google Ads Account. This should be 10-digits and in XXX-XXX-XXXX format.
Conversion action ID
Type: string
Required: True
You will find this information in the event snippet for your conversion action, for example send_to: AW-CONVERSION_ID/AW-CONVERSION_LABEL. This should be in the AW-CONVERSION_ID format.
Google Click ID (gclid)
Type: string
Required: True
The Google click ID (gclid) associated with this conversion.
Conversion Date Time
Type: string
Required: True
The date time at which the conversion occurred. Must be after the click time. The timezone must be specified. The format is "yyyy-mm-dd hh:mm:ss+|-hh:mm", e.g. "2019-01-01 12:32:45-08:00".

FAQ

Is the source code for this destination available?

PostHog is open-source and so are all the destination on the platform. The source code is available on GitHub.

Who maintains this?

This is maintained by PostHog. If you have issues with it not functioning as intended, please let us know!

What if I have feedback on this destination?

We love feature requests and feedback. Please tell us what you think.

What if my question isn't answered above?

We love answering questions. Ask us anything via our community forum.

Questions?

Was this page useful?

Next article

Send data to Google Cloud Storage

Send event data from PostHog to Google Cloud Storage. You'll also need access to the relevant Google Cloud account. Installation In PostHog, click the " Data pipeline " tab in the left sidebar. Click the 'Destinations' tab. Search for 'Google Cloud Storage' and select the destination. Connect your Google Cloud account at the configuration step. Press 'Create & Enable' and watch your 'events' get populated in Google Cloud Storage! Configuration FAQ Is the source code for this destination…

Read next article