# ChatGPT Ads UTM Parameters

> Set up ChatGPT Ads UTM parameters with the OpenAI dynamic macros so AnyTrack attributes conversions and campaign metrics to the right campaign, ad group, and ad in the Campaign Report.

## Why UTM Parameters Matter for ChatGPT Ads

The [ChatGPT Ads integration](/docs/chatgpt-ads) sends your conversions to OpenAI and fetches your campaign metrics. The UTM parameters tell AnyTrack which campaign, ad group, and ad served each click. AnyTrack reads the parameters from the landing page URL and attributes each visit and conversion to the campaign. Without UTM parameters, the [Campaign Report](/docs/campaign-report) groups all ChatGPT Ads traffic under `(not set)`.

## About ChatGPT Ads

OpenAI serves ads inside ChatGPT and manages them through Ads Manager. Ads Manager is in beta, and OpenAI adds measurement features over time. Before you launch new campaigns, verify the current macro list against the OpenAI [Measure Results guide](https://help.openai.com/en/articles/20001214).

<Prerequisites
  title="Before you begin"
  items={[
    { label: "You have an OpenAI Ads Manager account with an active campaign", done: true },
    { label: "The AnyTrack Tracking Tag is installed on your landing pages", done: true },
    { label: "You connected ChatGPT Ads in Tracking Pixels (recommended, for campaign metrics and Conversion API delivery)", done: true },
  ]}
/>

## ChatGPT Ads UTM Parameters Template

```http
utm_source=chatgpt&utm_medium=cpc&utm_id={campaign_id}&ad_group_id={ad_group_id}&ad_id={ad_id}&utm_content={ad_group_id}&utm_campaign={campaign_id}
```

Ads Manager fills each `{curly brace}` macro with a real value when the ad serves. The template carries the ad group and ad IDs as standalone parameters (`ad_group_id`, `ad_id`). The [Reddit](/docs/reddit-ads) and [Google Ads](/docs/google-ads-utm-parameters) templates use the same pattern. Attribution reaches the individual ad without `utm_term`.

### Add the Template in Ads Manager

1. In Ads Manager, open the **Campaigns** page.
2. Click the three-dot menu on the campaign and select **Edit campaign**.
3. Enter the template in the **Landing page query parameters** field.
4. Save your changes.

<Image src={readmeAsset1} alt="The Edit campaign modal in OpenAI Ads Manager. The Landing page query parameters field is highlighted, with the AnyTrack UTM template entered." border={true} align="center" caption={"Enter the UTM template in the Landing page query parameters field of the Edit campaign modal."} />

The same field exists for ad groups and ads. On the **Ad Groups** or **Ads** page, click the three-dot menu. Select **Edit ad group** or **Edit ad**.

<Callout icon="📘" theme="info">
**Note**

Ads Manager applies the most specific setting. The precedence order is: Ad URL, then Ad, then Ad Group, then Campaign. A parameter set at a more specific level takes precedence over the same parameter at a broader level. Set the template once at the campaign level. Leave the other levels empty, so one template governs each campaign.
</Callout>

## UTM Parameter Breakdown

Each parameter serves a specific purpose in your attribution chain:

| Parameter | Value | What It Tells AnyTrack |
|-----------|-------|----------------------|
| `utm_source` | `chatgpt` | The traffic source is ChatGPT Ads |
| `utm_medium` | `cpc` | The visit came from a paid click |
| `utm_id` | `{campaign_id}` | The campaign ID as a standard campaign identifier |
| `ad_group_id` | `{ad_group_id}` | The ad group, passed as a standalone parameter for reporting |
| `ad_id` | `{ad_id}` | The individual ad, passed as a standalone parameter for reporting |
| `utm_content` | `{ad_group_id}` | The ad group that served the ad |
| `utm_campaign` | `{campaign_id}` | The campaign that served the ad |

## Supported Macros

The **Landing page query parameters** field lists five supported template values. Ads Manager fills each value when the ad serves.

| Macro | Returns |
|-------|---------|
| `{campaign_id}` | The ID of the campaign |
| `{ad_group_id}` | The ID of the ad group |
| `{ad_id}` | The ID of the ad |
| `{ad_account_id}` | The ID of the ad account |
| `{oppref}` | OpenAI's click reference (see [About the oppref Parameter](#about-the-oppref-parameter)) |

## The Macros Return IDs, Not Names

The ID macros return IDs. OpenAI does not offer template values for campaign, ad group, or ad names. AnyTrack matches the IDs from the UTM parameters with the campaign metrics from your connected ChatGPT Ads account. The Campaign Report then shows the campaign structure with spend and results on each row. [Connect ChatGPT Ads](/docs/chatgpt-ads) before you compare the report with Ads Manager.

If you prefer a readable label in `utm_campaign`, replace `{campaign_id}` with a static label, for example `utm_campaign=spring-sale`. Keep the dynamic macros in `utm_content`, `ad_group_id`, and `ad_id`, so ad group and ad attribution stays intact. Each campaign then needs a template of its own.

## How AnyTrack Uses These Parameters

When a visitor arrives from a ChatGPT Ads click, AnyTrack reads the UTM parameters from the URL. AnyTrack stores them alongside the `click_id`. When that visitor converts, AnyTrack attributes the conversion with the full campaign context.

This data flows into:

- Your [Campaign Report](/docs/campaign-report), next to the campaign metrics from ChatGPT Ads
- [Event Attributes](/docs/event-attributes) sent to your connected ad platforms
- Custom audiences built from rules based on UTM parameters and events

## About the oppref Parameter

OpenAI appends the parameter `oppref` to every landing page URL from a ChatGPT Ads click. `oppref` is the OpenAI click reference. `gclid` on Google Ads and `fbclid` on Meta Ads play the same role. The **Landing page query parameters** field lists `{oppref}` as a template value. Do not add the parameter: OpenAI appends `oppref` automatically. AnyTrack reads the value and stores the value with the visitor journey. AnyTrack sends the value with each conversion through the Conversion API. See [The oppref Click Reference](/docs/chatgpt-ads#the-oppref-click-reference).

## Common Mistakes

**Expecting names from the macros.** The dynamic macros return IDs. AnyTrack matches the IDs with the campaign metrics from your connected ChatGPT Ads account. If ChatGPT Ads is not connected in Tracking Pixels, the Campaign Report shows the raw IDs. See [The Macros Return IDs, Not Names](#the-macros-return-ids-not-names).

**Setting parameters at more than one level.** The most specific level takes precedence: Ad URL, then Ad, then Ad Group, then Campaign. A parameter on one ad overrides the campaign template for that ad. Keep the template at the campaign level unless you have a specific reason to override.

**Adding oppref to the template.** OpenAI appends `oppref` automatically. Leave the parameter out of your template.

**Treating beta behavior as permanent.** OpenAI changes Ads Manager over time. If a parameter stops filling, verify the macro list against OpenAI's [Measure Results guide](https://help.openai.com/en/articles/20001214).

<FaqAccordion
  title="ChatGPT Ads UTM FAQ"
  icon="fa-duotone fa-circle-question"
  items={[
    {
      question: "Does AnyTrack send conversions to ChatGPT Ads?",
      answer: "Yes. Connect ChatGPT Ads in Tracking Pixels. AnyTrack then sends each mapped conversion to OpenAI through the Conversion API. The UTM parameters on this page attribute the same conversions in your Campaign Report. See the <a href='/docs/chatgpt-ads'>ChatGPT Ads guide</a>."
    },
    {
      question: "Why does my Campaign Report show IDs instead of campaign names?",
      answer: "The ChatGPT Ads macros return IDs, and OpenAI does not offer macros for names. AnyTrack matches the IDs with the campaign metrics from your connected ChatGPT Ads account. If the account is not connected in Tracking Pixels, the rows show the raw IDs. For a readable label, enter a static value in <code>utm_campaign</code>. Example: <code>utm_campaign=spring-sale</code>."
    },
    {
      question: "At which level should I set the landing page query parameters?",
      answer: "Set the template at the campaign level. Ads Manager applies the most specific setting: Ad URL, then Ad, then Ad Group, then Campaign. A template on one ad group or ad overrides the campaign template. Keep the other levels empty. Add a template on a lower level only for a deliberate override."
    },
    {
      question: "Do I need to add oppref to my UTM template?",
      answer: "No. OpenAI appends <code>oppref</code> to your landing page URLs automatically. AnyTrack reads the value and sends the value with each conversion through the Conversion API. You do not need to add the parameter to your <b>Landing page query parameters</b>."
    }
  ]}
/>

## Related Articles

- [ChatGPT Ads](/docs/chatgpt-ads)
- [Campaign Report](/docs/campaign-report)
- [Custom UTM Parameters](/docs/custom-utm-parameters)
- [Install the AnyTrack Tracking Tag](/docs/install-anytrack-tag)
