# OpenAI Pixel and ChatGPT Ads Conversion Tracking for B2B

> Set up the OpenAI pixel in Google Tag Manager and connect HubSpot with its own ChatGPT Ads integration. Then look at HubSpot and the 'how did you find us' answers to see what the ads brought in.

By Alex Rangevik · ChatGPT Ads · Updated November 29, 2026 · https://www.alexrangevik.com/post/openai-pixel-conversion-tracking

When a client tells me ChatGPT Ads shows zero conversions, the first thing I check is how the OpenAI pixel is set up in Google Tag Manager. The second is whether HubSpot is connected.

A B2B campaign won't get many leads straight from ChatGPT anyway, so the pixel is mostly there to give Ads Manager something to optimize for. To see what the ads actually brought in, we look in HubSpot and at what people write in the "how did you find us" field.

## TL;DR

Load the pixel through GTM once the visitor has accepted cookies, send one standard event per action, connect HubSpot and judge the ads in your CRM.

-   Install the OpenAI pixel in Google Tag Manager
-   Send one event per action
-   Load the pixel after consent
-   Test that OpenAI gets the event
-   Connect HubSpot to ChatGPT Ads
-   Judge the ads in HubSpot and "how did you find us"

Open your GTM container and check that the lead event fires on the thank-you page and not when someone opens the form. Then run the pixel test in Ads Manager before the campaign goes live.

## Install the OpenAI pixel in Google Tag Manager

I add the pixel as a Custom HTML tag in GTM, with the snippet and the Pixel ID from Ads Manager. You create the pixel under Conversions, Data Sources, and every event you send later goes to that same source.

The base tag loads OpenAI's script and runs `oaiq("init", ...)`. Each event then gets its own Custom HTML tag with an `oaiq("measure", ...)` call and its own trigger.

If your site has a Content Security Policy, it has to allow bzrcdn.openai.com and bzr.openai.com, or the browser blocks the pixel. The exact directives are in [OpenAI's pixel guide](https://developers.openai.com/ads/measurement-pixel). While you test, add `debug: true` to the init call and the pixel logs what it does in the browser console.

## Send one event per action

I send each action as its own standard event, since Ads Manager [only optimizes for standard events](https://help.openai.com/en/articles/20001412-conversion-optimized-campaigns) and only one per campaign. These are the [standard events](https://developers.openai.com/ads/supported-events) that fit B2B:

| Action | OpenAI event | Data type | Trigger in GTM |
|---|---|---|---|
| Engaged visit, 90 seconds | page_viewed | contents | Timer that fires once |
| Contact or demo form sent | lead_created | customer_action | Thank-you page or form event |
| Meeting booked | appointment_scheduled | customer_action | Booking confirmation |
| Trial started | trial_started | plan_enrollment | Sign-up confirmation |

The tag for a lead looks like this:

```html
<script>
  oaiq("measure", "lead_created", { type: "customer_action" });
</script>
```

For the timer it's `page_viewed` with `{ type: "contents" }`, since that's the event type I give [the engaged visit in Ads Manager](/post/chatgpt-ads-manager).

Fire the lead event on the thank-you page or on the form's own submit event, the same way as in my [form tracking guide](/post/easy-form-conversion-tracking-with-google-tag-manager). A trigger on the page with the form counts everyone who opened it.

Custom events work in the reports but can't be the campaign goal. And if you also send the event from your server, give both copies the same event_id so OpenAI only counts it once.

## Load the pixel after consent

In the EU I only let the pixel load after the visitor has accepted cookies. The pixel itself assumes consent as soon as it loads, unless you call `oaiq("consent", false)` before init and `oaiq("consent", true)` after the yes.

On my own site, the cookie banner doesn't load GTM at all until the visitor accepts. For one client, the pixel tag fires on the banner's accept event and also has GTM's consent checks for ad_storage, ad_user_data and ad_personalization. Nothing goes to OpenAI before someone in the EU has said yes.

In the US the same client's pixel runs without an active yes, and the page views OpenAI attributed to the ads matched the ChatGPT sessions in GA4 almost one to one. In Europe the banner takes [a good share of the sessions](/post/chatgpt-b2b-verdict), and the pixel loses the same visitors.

## Test that OpenAI gets the event

Ads Manager has its own test mode for the pixel:

1.  Go to Conversions, Data Sources.
2.  Open the three-dot menu on your web pixel and pick Test.
3.  Enter the URL of a page with the pixel and click Start testing.
4.  Do the action in the tab that opens, like waiting out the timer or sending the form.
5.  Go back to Event Stream and look for the events with the Test label.

The test runs for 30 minutes and only covers that tab on the same domain, so a form on a subdomain or a booking tool on another site won't show up. Test events also count in the normal reports ([OpenAI's troubleshooting guide](https://help.openai.com/en/articles/20001604-troubleshooting-conversion-tracking-for-chatgpt-ads)). And attributed conversions take 24 to 48 hours to show up in the campaign report, so don't panic the morning after launch.

## Connect HubSpot to ChatGPT Ads

I connect the ad account with HubSpot's own ChatGPT Ads integration. In HubSpot you go to Settings, Marketing, Ads, click Connect account and pick ChatGPT Ads. It works on [every Marketing Hub tier](https://help.openai.com/en/articles/20001522-setting-up-chatgpt-ads-in-hubspot), Free included.

HubSpot then shows impressions, clicks, contacts, customers and cost per campaign, ad group and ad, and you can compare ChatGPT with your other ad channels under Analyze.

If your company uses ChatGPT Business or Enterprise, a global admin has to approve HubSpot's Ads access in OpenAI's Admin Console first. It's off by default, so that's one more ticket to IT.

## Judge the ads in HubSpot and "how did you find us"

For one client, AI search like ChatGPT and Copilot has been 4.2% of the "how did you find us" answers since September, against 3.0% for 2026 as a whole. In HubSpot those contacts had Google Ads, direct traffic or organic AI as the source, so without the field you'd only see ChatGPT in some of them.

It's the same question I put on [every contact form](/post/linkedin-insight-tag-conversion-tracking), and I read the answers next to the contacts and customers HubSpot shows per ChatGPT campaign.

## Common questions

### Do you need the Conversions API for ChatGPT Ads?

Not for a first test. I'd start with the pixel and add the Conversions API when you scale and want MQLs from your CRM as the goal. It needs a Pixel ID even if you never install the pixel, and it only takes events from the last seven days. The API also doesn't pick up OpenAI's click reference by itself, so your server has to pass it along ([OpenAI's conversion tracking docs](https://developers.openai.com/ads/conversion-tracking)).

### What attribution window does ChatGPT Ads use?

I set my conversion events to 30 days after a click and 1 day after a view. With a one-day view window the Conversions column in Ads Manager [includes both](https://help.openai.com/en/articles/20001604-troubleshooting-conversion-tracking-for-chatgpt-ads), and with zero days it only counts clicks.

### What is oppref in the landing page URL?

It's OpenAI's click reference, added to the end of the URL when someone clicks your ad. The pixel saves it in a first-party cookie called __oppref for 30 days, so a lead that comes back a week later can still be tied to the click. Make sure your redirects keep it ([OpenAI's conversion measurement guide](https://help.openai.com/en/articles/20001409-conversion-measurement)).

### Does the OpenAI pixel read form fields?

It does, by default. Automatic advanced matching picks up things like email addresses from forms, hashes them with SHA-256 in the browser and sends the hash with the conversion. Outside Japan you can't turn it off in Ads Manager, so put the pixel in your privacy policy next to the other ad pixels.

### Can you connect GA4 to ChatGPT Ads Manager?

You can, but it's in beta and you have to ask your OpenAI account manager for access. Ads Manager then imports aggregated reports from the property every day, and you map your GA4 events to OpenAI's, like generate_lead to Lead Created. The totals cover all your traffic sources, so they aren't campaign conversions ([OpenAI's GA4 guide](https://help.openai.com/en/articles/20001562-connecting-google-analytics-4-to-openai-ads-manager)).

*ChatGPT Ads facts checked against OpenAI Help and OpenAI's developer docs in November 2026. Client numbers are from Ads Manager, GA4 and HubSpot from September to November 2026.*
