Skip to main content
AI AdsBy Kevin O'Connell15 min readPublished May 12, 2026Updated November 4, 2026

How to install the ChatGPT Ads Measurement Pixel via Google Tag Manager

OpenAI launched the ChatGPT Ads Measurement Pixel on May 5, 2026. Three install paths via GTM: the AI-Advisors ChatGPT Ads integration (paste your Pixel ID, pick your container, publish; two minutes, Growth+ plans), the free open-source OpenAI Ads Pixel community template, or a manual Custom HTML tag for full control. Plus event wiring, verification, and Conversions API dedup.

There are three ways to install the ChatGPT Ads Measurement Pixel via Google Tag Manager. The fastest is the AI-Advisors ChatGPT Ads integration: paste your OpenAI Pixel ID, pick your GTM container, and publish in GTM. Two minutes, no developer required, available on Growth+ plans. For a free no-code route, add the open-source OpenAI Ads Pixel community template from the GTM gallery and configure it with your Pixel ID. Or paste OpenAI's official init snippet into a Custom HTML tag yourself for full control. This guide walks all three.

  • ChatGPT Ads integration (recommended): Paste Pixel ID → Select GTM container → Publish in GTM (~2 min, Growth+ plans)
  • Community GTM template: Add the open-source OpenAI Ads Pixel template from the GTM gallery → configure Pixel ID → Publish (~5 min, free)
  • Official OpenAI GTM template: OpenAI also publishes its own OpenAI Ads Measurement Pixel template in the same gallery (free, Apache-2.0), a leaner alternative to the community template
  • B2B lead-gen GTM template: Our ChatGPT Ads Pixel for B2B template checks every event against OpenAI's rules before sending, so leads are not silently dropped (free, Apache-2.0, installs from GitHub while in Google's gallery review)
  • Manual install: Custom HTML tag with OpenAI's official snippet → All Pages trigger → Publish workspace (~10 min)
  • Pixel launched: May 5, 2026 (same day the Ads Manager opened to all US advertisers)
  • Standard events supported: 10 (page_viewed, contents_viewed, items_added, checkout_started, order_created, lead_created, registration_completed, appointment_scheduled, subscription_created, trial_started) plus custom
  • SDK function: oaiq("measure", eventName, eventProps, eventOptions)

OpenAI shipped the ChatGPT Ads Measurement Pixel on May 5, 2026, the same day the Ads Manager opened to every US advertiser with no account minimum. The pixel is a browser SDK that fires a global oaiq() queue, captures the oppref identifier from ChatGPT ad clicks, and reports 10 standard conversion events (plus custom events) back to your OpenAI Ads account. OpenAI's docs also call it the OpenAI Pixel, and OpenAI's own Tag Manager template is named OpenAI Ads Measurement Pixel, so all three names mean the same thing.

You have three install options. The faster path is the AI-Advisors ChatGPT Ads integration: paste your OpenAI Pixel ID, pick your GTM container, and click through to publish. Two minutes inside AI-Advisors plus one publish click in GTM, no developer required, available on Growth+ plans. The no-code middle ground is the open-source OpenAI Ads Pixel community template, listed in the GTM Community Template Gallery: add it to your workspace, enter your Pixel ID, and configure events through validated fields instead of raw HTML. OpenAI also publishes an official template, OpenAI Ads Measurement Pixel, in the same gallery. The manual path is to paste OpenAI's official init snippet into a Custom HTML tag in your GTM container yourself, set it to fire early on every page, and publish the workspace. About 10 minutes if you have your Pixel ID ready, no third-party dependencies, useful when you want full control over the install.

This guide walks all three paths. Pick whichever fits your team. Then we set up consent, wire all 10 standard conversion events, make them count as conversions in Ads Manager, verify with the GTM Preview debugger, troubleshoot the common failure modes, and optionally pair the pixel with the Conversions API for browser-and-server deduplication.

The pixel is one HTTP call and a queue. The hard part is getting it onto every page, gated by consent, and deduplicated with your server. GTM solves all three.

What the ChatGPT Ads Measurement Pixel does

The pixel loads OpenAI's minified SDK from bzrcdn.openai.com/sdk/oaiq.min.js, initializes a global oaiq() queue tied to your Pixel ID, and exposes a single function call signature for conversion events:

JavaScript
oaiq("measure", eventName, eventProps, eventOptions);

On every page load, the SDK captures the oppref query parameter from the URL (OpenAI's privacy-preserving ad-click identifier), stores it in a first-party __oppref cookie so later visits can reuse it (the cookie lasts 30 days, and each new ad click restarts the 30 days), adds the current page origin assource_url, timestamps each event, and batches closely grouped calls. None of this needs configuration.

How OpenAI counts the results is set in Ads Manager, not in your tag. Its guide to measuring results lets you choose a 7-, 14- or 30-day click-through window and a one-day view-through window (someone saw the ad, did not click, and converted within a day), or switch view-through off. With view-through on, the Conversions total includes both kinds, and separate columns split them. Your pixel install is the same either way.

For the strategic context (why this pixel matters, what the April 30 privacy policy unlocked, the full roadmap), see our deep-dive on ChatGPT Ads conversion tracking. This guide is the implementation companion.

Prerequisites

  • OpenAI Ads account. Sign in at ads.openai.com. Self-serve is open to advertisers in 89 countries, the US included, with no account minimum since May 5, 2026; OpenAI documents a per-campaign daily minimum that varies by billing currency (US $25/day, September 2026).
  • Pixel ID. Create one in the Conversions tab inside Ads Manager. Treat it as semi-public (it appears in your page source).
  • GTM container active on your site. If you do not have GTM installed yet, that is a separate one-time install at tagmanager.google.com.
  • Publish access in GTM. "Edit" access is not enough; you need "Publish" rights to push the tag live (either path).

One-click install: AI-Advisors ChatGPT Ads integration (2 minutes)

For marketers who do not want to manually wire a Custom HTML tag, the AI-Advisors ChatGPT Ads integration handles the GTM setup in three steps. The integration is included on Growth+ plans, takes about 2 minutes inside AI-Advisors plus one publish click in GTM, and uses OpenAI's official init snippet under the hood (the same snippet the manual path below uses).

STEP 1: Paste your OpenAI Pixel ID

~30 sec

Provision a Pixel ID in the Conversions tab of Ads Manager (same as the manual path). Open AI-Advisors, navigate to Integrations → ChatGPT Ads, and paste your Pixel ID into the form.

STEP 2: Select your GTM container

~60 sec

Connect Google Tag Manager and select the container where your site lives. Google's sign-in asks for one permission, Tag Manager container editing. Google applies it to every container your Google account can edit, because it offers no single-container option, and it excludes publishing. AI-Advisors writes only its own draft tag to the container you pick, and the Tag Manager connection does not ask for access to Analytics, Search Console or Google Ads.

STEP 3: Publish in GTM

~30 sec

AI-Advisors stages a draft Custom HTML tag named ChatGPT Ads Measurement Pixel in your GTM workspace. It fires on the built-in Initialization - All Pages trigger with a firing priority of 100, so the pixel loads near the top of every page. Until you publish, the ChatGPT Ads row in AI-Advisors shows an amber Draft badge with a link into the exact workspace. Open GTM, click Publish on the workspace version (one click), and the pixel goes live within minutes.

What the integration installs

A Custom HTML tag firing OpenAI's official init snippet from bzrcdn.openai.com/sdk/oaiq.min.js, wired to the built-in Initialization - All Pages trigger. It is the same tag the manual walkthrough below builds, plus a firing priority so it runs ahead of other tags on that trigger. The integration does not publish the workspace for you, so you keep full control over what goes live.

Skip the manual setup. Paste your Pixel ID, pick your GTM container, publish in GTM. Available on Growth+ plans, 2 minutes from start to staged tag.

Connect the ChatGPT Ads integration →

No-code option: a GTM gallery template (official or community)

OpenAI shipped the Measurement Pixel on May 5, 2026 with an SDK but no Google Tag Manager template, so unlike the Meta or TikTok pixels, early adopters had to wire a Custom HTML tag by hand. The community closed that gap: there is now an open-source OpenAI Ads Pixel template (maintained by Stape, Apache-2.0) listed in the GTM Community Template Gallery. It wraps OpenAI's standard pixel events in validated GTM fields, so you get a structured, no-code install without writing or maintaining raw HTML. OpenAI's own measurement partner guide now lists Stape, alongside Datahash, as a third-party tool for implementing the pixel and Conversions API, including deduplication of events sent through both.

OpenAI followed with its own official template, OpenAI Ads Measurement Pixel (Apache-2.0, published on GitHub in June 2026), now in the same gallery. The two differ in how much they do for you. OpenAI's is lean: one tag per event, with fields for the event, amount, currency, plan, contents, and user identifiers you have already hashed yourself. Stape's adds Google Consent Mode gating, automatic parameter mapping from a GA4-style Data Layer, and in-browser hashing of raw email, phone, and name values. The steps below follow Stape's template; with OpenAI's, you fill in step 3 by hand and wire the consent gating in step 4 yourself.

We built a third template for lead generation: ChatGPT Ads Pixel for B2B (by AI-Advisors, Apache-2.0). OpenAI's pixel checks every event in the browser and drops any that break its rules, while GTM still reports the tag as fired. One way this happens on lead-gen sites: a page records a product view earlier, the template copies that ecommerce data onto the lead, and OpenAI drops the lead because lead events cannot carry product contents. Our template checks each event against OpenAI's rules before sending it, keeps ecommerce data off lead, demo, signup, and trial events, fixes what it safely can, and marks the tag as Failed with the reason in GTM Preview when it cannot. It also uses OpenAI's own consent command and generates event IDs for Conversions API deduplication. It was submitted to Google's gallery on October 13, 2026 and is in review, so for now install it from GitHub: download template.tpl, then in GTM open Templates, click New under Tag Templates, and choose Import from the ⋮ menu.

STEP 1: Add the template from the GTM gallery

~1 min

In your GTM web workspace, open Templates, then under Tag Templates click Search Gallery. Search for OpenAI Ads. Two results matter: OpenAI Ads Pixel by Stape (the community template these steps follow) and OpenAI Ads Measurement Pixel (OpenAI's official template). Add the one you picked to your workspace.

STEP 2: Create a tag and enter your Pixel ID

~2 min

Click Tags, then New, and pick the OpenAI Ads Pixel template as the tag type. Paste your Pixel ID (from the Ads Manager Conversions tab) into the template's Pixel ID field.

STEP 3: Choose your event and parameter mapping

~2 min

Set the event name (the base tag defaults to page_viewed). The template can map event parameters automatically from a GA4-style ecommerce Data Layer, or you can set amount, currency, and contents by hand. The same 10 standard events documented below are available as template options.

STEP 4: Configure consent, then add a trigger and publish

~3 min

The template exposes a Consent section that integrates with GTM Consent Mode, so you can gate firing on consent without writing the check yourself. Add the Initialization - All Pages trigger for the base pixel so it loads early (plain All Pages also works), or specific conversion triggers for events, then Save, preview, and Publish the workspace.

Template vs integration vs manual

The community template is free and gallery-listed, and it fires the same OpenAI standard events as the other two paths. You still wire each conversion event, consent gating, and browser-and-server deduplication yourself. The AI-Advisors integration stages the tag for you and ties the pixel into citation and AEO reporting; the manual snippet below gives you full control with no third-party template. Pick the trade-off that fits your team. OpenAI's official template is the leaner alternative if you would rather run the vendor's own code and handle consent and hashing yourself.

Manual install via Custom HTML tag in GTM (10 minutes)

If you prefer no third-party template at all (full visibility into exactly what runs on your site), wire the Custom HTML tag yourself. The manual path takes five steps, and the snippet you paste is OpenAI's published snippet with one testing setting added, so you can check it line by line against OpenAI's docs.

STEP 1: Get your Pixel ID from Ads Manager

~2 min

Sign in to ads.openai.com, open the Conversions tab, create a pixel (OpenAI's docs also call it a data source), name it (e.g. "Main site pixel"), and copy its Pixel ID exactly. A wrong ID does not error; events just go nowhere.

STEP 2: Create a Custom HTML tag in GTM

~2 min

Open your GTM workspace. Click Tags, then New, then Tag Configuration. Pick Custom HTML. Name the tag explicitly: OpenAI Ads Pixel - Init. Naming matters; you will want to find this tag quickly when you debug later.

STEP 3: Paste OpenAI's official init snippet

~2 min

Paste the snippet below into the HTML field. Replace <YOUR-PIXEL-ID> with the ID you copied in Step 1. Keep debug: true while testing; remove it before publishing to production.

HTML
<script>
  (function (w, d, s, u) {
    if (w.oaiq) return;
    var q = function () {
      q.q.push(arguments);
    };
    q.q = [];
    w.oaiq = q;
    var js = d.createElement(s);
    js.async = true;
    js.src = u;
    var f = d.getElementsByTagName(s)[0];
    f.parentNode.insertBefore(js, f);
  })(window, document, "script", "https://bzrcdn.openai.com/sdk/oaiq.min.js");

  oaiq("init", {
    pixelId: "<YOUR-PIXEL-ID>",
    debug: true,
  });
</script>

STEP 4: Set the Initialization - All Pages trigger

~1 min

Under Triggering, pick the built-in Initialization - All Pages trigger. It fires before the regular All Pages (page view) trigger, so the pixel loads as early as Tag Manager allows. OpenAI recommends loading the pixel near the top of the page so early conversions are not lost. Leave Consent Initialization - All Pages for your consent banner.

The pixel needs to load on every page so the SDK can capture oppref from the landing URL and store it in the first-party __oppref cookie for later events to reuse.

STEP 5: Save, submit, and publish the workspace

~3 min

Click Save. Open GTM Preview to verify the tag fires on every page (more on verification below). When the debugger confirms the tag and a network request to bzrcdn.openai.com, click Submit, name the version (e.g. "OpenAI Ads Pixel install"), and Publish. The pixel is live within minutes.

Before you publish: set up consent

OpenAI's pixel measures by default, and a Custom HTML tag has no consent checks of its own. If your visitors must opt in first, set up two things.

Gate the tag. In the tag's Advanced Settings, open Consent Settings, choose "Require additional consent for tag to fire", and addad_storage. Add ad_user_data too if you pass customer data. Tag Manager then holds the pixel back until your consent banner reports consent.

Handle withdrawals. Blocking a tag does not remove cookies the pixel already set. OpenAI's pixel has its own consent command for that: oaiq("consent", false) stops measurement and removes both of the pixel's cookies. Fire it from a small Custom HTML tag on the event your consent platform pushes when a visitor withdraws. Events blocked after that are not sent later, and the pixel remembers the choice on later pages until it is told oaiq("consent", true). Because the gated pixel tag only runs once consent is granted, put that line in the pixel tag, just above oaiq("init", ...), so a visitor who opts back in is measured again. Consent is on by default, so the line changes nothing for everyone else.

HTML
<script>
  // Separate tag, fired on your consent platform's "consent withdrawn" event
  if (window.oaiq) oaiq("consent", false);
</script>
JavaScript
// In the pixel tag, just above oaiq("init", ...)
oaiq("consent", true);

Stape's gallery template gates the tag on Consent Mode for you, and our B2B template also sends OpenAI's consent command when consent is denied or withdrawn. OpenAI's official template does not handle consent.

Wire your conversion events

Either install path puts the pixel SDK on every page. Conversion events are separate Event tags you fire on the actions that matter (form submit, button click, purchase confirmation). OpenAI's Measurement Pixel supports 10 standard event names plus a custom event. Each maps to one of four data shapes: contents, customer_action, plan_enrollment, or custom.

Event nameData shapeUse for
page_viewedcontentsPage loads, important page views
contents_viewedcontentsProduct, listing, or article views
items_addedcontentsCart adds, bundle selections
checkout_startedcontentsCheckout begun
order_createdcontentsPurchase completed
lead_createdcustomer_actionLead form submitted, contact request
registration_completedcustomer_actionAccount or event registration finished
appointment_scheduledcustomer_actionMeeting, demo, or consultation booked
subscription_createdplan_enrollmentPaid subscription started
trial_startedplan_enrollmentFree trial started
customcustomAnything not in the standard taxonomy

Example: fire a lead_created event on form submit

Add a GTM Custom HTML or Event tag triggered by your lead form submit event:

JavaScript
oaiq("measure", "lead_created", {
  type: "customer_action",
});

Example: fire order_created with deduplication-ready event_id

On a purchase confirmation page, fire the event with a unique event_id so you can deduplicate against a server-fired Conversions API event with the same ID:

JavaScript
oaiq("measure", "order_created", {
  type: "contents",
  amount: 12999,
  currency: "USD",
  contents: [
    {
      id: "sku_123",
      name: "Starter bundle",
      content_type: "product",
      quantity: 1
    }
  ]
}, {
  event_id: "order_12345"
});

Example: fire a custom event

For events outside the standard taxonomy, keep eventName as custom, set type to custom in eventProps, and put the label in eventOptions.custom_event_name (not eventProps):

JavaScript
oaiq("measure", "custom", {
  type: "custom",
  amount: 12999,
  currency: "USD"
}, {
  custom_event_name: "quote_requested",
  event_id: "quote_req_456"
});
Common mistake

Putting custom_event_name or event_id inside eventProps instead of eventOptions. They go in the fourth argument (options), not the third (props). OpenAI's SDK silently drops them if they are in the wrong object.

Optional: pass customer data to raise the match rate

The pixel accepts an optional user object on init. It is not required for the install to work, and everything above is complete without it. Its only job is to improve the odds that OpenAI can match a converting visitor to a logged-in ChatGPT user, the same job automatic advanced matching does from your website forms.

Five fields are hashed with SHA-256: email, phone number, external ID, first name, and last name. Four are sent in the clear: country as a two-letter ISO 3166-1 code, city, region, and postal code. That split is the part teams most often get wrong, since region and postal code look like they should be hashed and are not.

Normalization is prescribed, not suggested. Trim and lowercase an email before hashing. Reduce a phone number to 8 to 15 digits, removing a leading plus, leading zeroes, whitespace, parentheses, periods, and hyphens. Lowercase names and strip whitespace and ASCII punctuation, leaving non-ASCII characters in place. Hash after normalizing, never before, or the match fails silently.

Only send fields you already hold lawfully for this purpose. Hashing limits what OpenAI sees; it does not manufacture consent, and a successful match still confirms to the platform that the person exists in both graphs.

Make the events count as conversions in Ads Manager

Sending an event is not the same as counting it. In OpenAI's setup, a conversion event setting picks which event, from which pixel, counts as a conversion, and you attach that setting to the campaigns you want to measure. Until one does, a test lead can show up in Event Stream while the campaign's Conversions column stays at zero. It is an easy step to miss, because nothing in Tag Manager tells you about it.

  • Clicks and Reach campaigns can report conversions without changing their objective. Attach one or more conversion event settings.
  • Conversions campaigns optimize toward exactly one event, chosen when you create the campaign. It must be a standard event such as lead_created or appointment_scheduled, not a custom one, and it cannot be changed later.
  • Custom events can still count for reporting, as long as the setting uses exactly the same custom_event_name your tag sends.

Picking the right event for a B2B Conversions campaign is its own decision; our guide to ChatGPT Ads conversion campaigns walks through it.

Verify the install

Three verification layers, in order of speed:

1. GTM Preview mode

Click Preview in the top right of GTM. Open your site in the connected debug window. Navigate. The Tag Assistant panel should show your OpenAI Ads Pixel tag firing on every page. Check the Variables tab for the right Pixel ID. Check the Data Layer tab for the events you wired.

2. Browser console with debug: true

With debug: true in your init config, the SDK logs activity to the browser console. Open DevTools, refresh, and you should see SDK init messages and event payloads as they fire. Useful for confirming the Pixel ID is correct and that conversion events carry the right type, amount, currency, and any contents[] items.

3. Ads Manager events tab

Open Ads Manager, navigate to the Conversions tab, click your pixel, and look at the Events panel. Real events arrive within a few minutes of firing. If you do not see them, the issue is upstream of the network (the tag is not firing, the Pixel ID is wrong, or the event payload is malformed). For a live view, open the Event Stream tab under Conversions, pick your pixel, and press Start polling: it lists recent events with their payloads as OpenAI received them.

To review the whole setup from the outside, run the page through our free ChatGPT Ads Pixel Checker. It reads the page and your published Tag Manager container and lists the Pixel ID, the events set up, and settings known to drop conversions. For the full sequence, from that outside read to Event quality a week later, see how to check your pixel is working.

Troubleshooting

  • Tag is not firing. In GTM Preview, check whether the trigger condition matches. The most common cause is the trigger pointing at a custom event that your DataLayer never pushes.
  • Tag fires but no network request to bzrcdn.openai.com. The Init tag did not run before the Event tag, so oaiq is undefined. Use GTM tag sequencing ("Fire a tag before this tag fires") to guarantee Init runs first.
  • Events arrive at OpenAI but are not deduplicating with server events. Confirm the event_id on the pixel call matches the id on the Conversions API call. For custom events, also confirm custom_event_name matches on both sides.
  • Tag fires in GTM but the conversion never reaches Ads Manager. OpenAI's pixel validates each event in the browser and drops any that break its rules, without an error GTM can see. Turn on debug: true and look in the console for validation failed; event dropped, which names the problem. Common causes: a lead event carrying contents left over from an earlier ecommerce push (clear it with dataLayer.push({ ecommerce: null }) before the lead), a custom event name with a dot such as gtm.formSubmit, or an amount that is not a whole number of minor units.
  • Events arrive, Conversions stays at zero. No conversion event setting selects that event, or the campaign does not use it. See counting events as conversions above.
  • Your site blocks the pixel. A site that sends a Content Security Policy can block the pixel with no warning in Tag Manager; the browser console shows the error. OpenAI lists the sources to allow: https://bzrcdn.openai.com in script-src, https://bzr.openai.com and https://bzrcdn.openai.com in connect-src, and https://bzr.openai.com in img-src.
  • Pixel ID typo. A wrong Pixel ID will not error; events go to the void. Double-check against Ads Manager.
  • Custom event name validation failed. Use lowercase letters, numbers, underscores, or dashes. 1 to 64 characters. Do not reuse a standard event name.
  • Consent declined and pixel still fires. Require ad_storage in the tag's consent settings so it does not fire until the visitor has opted in, and send oaiq("consent", false) when they withdraw, as in the consent setup above.

When you need the image tag or more than one Pixel ID

Most sites need one JavaScript pixel in Tag Manager. OpenAI documents two variations for the cases that do not fit.

No JavaScript on the page: the image tag

OpenAI's image tag sends a conversion when a page loads without running JavaScript. It is a hidden 1×1 image whose address carries your Pixel ID and the event, and each image request sends one event. Placed inside a <noscript> element in your page template, it acts as a fallback that loads only when JavaScript is unavailable:

HTML
<noscript>
  <img
    src="https://bzr.openai.com/v1/sdk/events?pid=<YOUR-PIXEL-ID>&event=page_viewed&data[type]=contents"
    width="1"
    height="1"
    style="display:none"
    alt=""
  />
</noscript>

Know its limits before relying on it. Because it loads with the page, it cannot measure clicks, form submissions or anything that happens afterwards. It does not capture OpenAI's oppref attribution identifier for you, so pass that value yourself if you have it. As with the pixel, render it only after you have any consent your measurement needs. OpenAI also says not to wrap it in <noscript> when it is your only integration, because it then never loads for browsers that run JavaScript.

More than one Pixel ID on the same site

One site can measure conversions for more than one advertiser, brand or agency partner. OpenAI's multiple Pixel IDs guide says to load the pixel script once, initialize each Pixel ID, then choose where each event goes: measure sends it to every pixel initialized so far, and measureSingle sends it to one.

JavaScript
oaiq("init", { pixelId: "<PIXEL-ID-A>" });
oaiq("init", { pixelId: "<PIXEL-ID-B>" });

// Both pixels receive this event
oaiq("measure", "page_viewed", { type: "contents" });

// Only pixel A receives this one
oaiq("measureSingle", "<PIXEL-ID-A>", "order_created", {
  type: "contents",
  amount: 2599,
  currency: "USD",
});

Two details matter. A pixel you initialize later does not receive events sent before it, and an event addressed with measureSingle to a Pixel ID you never initialized is not sent to another pixel. In the manual Tag Manager install above, add one init line per Pixel ID to the base tag.

Pair the pixel with the Conversions API for browser-and-server dedup

The pixel alone loses conversions to ad blockers, browser tracking prevention (ITP, ETP), consent declines, and broken page rendering. The OpenAI Conversions API is the server-side companion that recovers those.

The dedup primitive is a shared event_id: when your server fires a conversion event, generate a unique ID and pass it to both the pixel (as event_id in eventOptions) and the Conversions API (as id in the event payload). OpenAI matches on the tuple of Pixel ID + event name + event_id and collapses duplicates into a single conversion.

Two practical notes for hybrid setups, both verified against the current documentation and shipped tooling on August 12, 2026. First, if your server-side tag logs Request was not sent with the reason Event ID is required., that is the widely used community Conversions API server tag (Stape's) enforcing, since its June 1, 2026 update, an event ID it never generates itself: mint one UUID per conversion in the browser, pass it as event_id on both sides, and the error and the duplicate-counting problem disappear together. Second, OpenAI added a browser-reference field to the Conversions API on July 16, 2026: the pixel stores a first-party __obref cookie, and hybrid integrations read it in the browser and pass it unchanged as user.obref on server events, consent permitting. The full four-identifier map (including the click ID and the commerce reference) is in our conversion tracking deep-dive.

That same deep-dive on ChatGPT Ads conversion tracking walks the full client-and-server stack, the strategic case for running both, and the April 30 OpenAI privacy policy that unlocked the pixel for general availability. For the programmatic-management side (campaign CRUD via the Advertiser API, reporting via the Insights API), see our companion post on how to get an OpenAI Ads API key. For the retargeting side (uploading hashed CRM lists as include or exclude audience filters), see ChatGPT Ads custom audiences. The pixel is the upstream measurement half; custom audiences are the downstream targeting half.

The pixel and the Conversions API are not redundancy. They are a quorum.

Skip the manual GTM setup entirely. Paste your OpenAI Pixel ID, pick your GTM container, publish in GTM. Available on Growth+ plans, 2 minutes from start to staged tag plus one publish click.

Connect the ChatGPT Ads integration →

See the clicks in GA4, not just conversions in Ads Manager

The pixel answers one question: how many conversions your ChatGPT campaigns produced, reported inside OpenAI's Ads Manager. It says nothing about what those visitors did on your site, and GA4 has no native idea that a session arrived from a ChatGPT ad. Tag your destination URLs with the canonical convention first, utm_source=chatgpt&utm_medium=cpc, which our guide to UTM codes for ChatGPT Ads covers in full. That alone keeps the clicks in GA4's paid channels (Paid Other under the default channel group; a one-rule custom channel group names it ChatGPT Ads).

To separate them properly, we publish a free open-source tag template: AI Crawler Analytics on GitHub (Apache 2.0). A click carrying that UTM pair becomes an ai_referral_visit event stamped ai_medium=paid, next to the operator and source that produced it. Paid ChatGPT clicks then sit in the same report as organic ChatGPT citations, told apart rather than blended, which is the comparison that tells you whether the ads are buying traffic you were already earning. The template sends data only to the GA4 property you configure. Nothing is sent to AI-Advisors.

This one needs a server container
The template runs in a GTM server container, not the web container you used for the pixel above. If you only run web GTM, the UTM convention still does the useful half of this job on its own: the clicks land in GA4's paid channels without any template at all.

Frequently Asked Questions

#How do I install the ChatGPT Ads Measurement Pixel in Google Tag Manager?

Get your Pixel ID from the Ads Manager Conversions tab, create a Custom HTML tag in your GTM container, paste OpenAI's official init snippet with your Pixel ID, set the built-in Initialization - All Pages trigger, then publish the workspace. Faster shortcuts are the AI-Advisors integration or the open-source community template.

#What does the AI-Advisors ChatGPT Ads integration do, and does it publish to GTM for me?

The integration adds OpenAI's pixel to your GTM container as a draft Custom HTML tag, set to load early on every page. You paste your OpenAI Pixel ID, connect Google Tag Manager, pick your container, and AI-Advisors stages the tag there. Google's sign-in asks for one permission, Tag Manager container editing, which covers the containers your Google account can edit and excludes publishing. AI-Advisors writes only its own tag to the container you pick. You then publish the workspace version yourself in GTM with one click. The integration does not publish to GTM on your behalf, so you keep full control over what goes live. Setup is about 2 minutes inside AI-Advisors plus one publish click in GTM. Available on Growth+ plans.

#When did OpenAI release the ChatGPT Ads Measurement Pixel?

OpenAI launched the JavaScript Measurement Pixel on May 5, 2026, the same day the Ads Manager opened to every US advertiser with no account minimum. The server-side Conversions API for event ingestion shipped on the same date. OpenAI publishes the pixel as a JavaScript snippet for the head of your pages, and that snippet is what both the AI-Advisors integration and the manual path place in a Custom HTML tag.

#Is there a Google Tag Manager template for the ChatGPT Ads pixel?

Yes, two, both free in the GTM Community Template Gallery. OpenAI publishes an official template (OpenAI Ads Measurement Pixel, Apache-2.0, released on GitHub in June 2026), and an open-source community template (the OpenAI Ads Pixel template, maintained by Stape) filled the gap before it. Both wrap OpenAI's standard pixel events in configurable GTM fields, so you can install without writing Custom HTML. OpenAI's template is the leaner of the two: you fill in the event, amount, currency, and any already-hashed user identifiers on each tag. Stape's adds Google Consent Mode gating, automatic parameter mapping from a GA4-style Data Layer, and in-browser hashing of raw email, phone, and name values. A third template, ChatGPT Ads Pixel for B2B, is built by AI-Advisors for lead generation: it checks each event against OpenAI's rules before sending, so a lead OpenAI would reject is fixed or flagged in GTM Preview instead of silently dropped. It installs from GitHub while Google reviews it for the gallery. In total there are three routes: the AI-Advisors integration (managed, stages the tag for you), a gallery template (free and no-code, but you configure events and consent yourself), and a manual Custom HTML tag (full control, no dependencies).

#Can I track ChatGPT Ads conversions without Google Tag Manager?

Yes. The simplest install is pasting OpenAI's init snippet directly into the head of every page that should fire the pixel. GTM is recommended because it centralizes tag management, supports versioning, gates by consent, and lets non-developers update conversion logic without touching the codebase. But it is not required. The pixel snippet is plain JavaScript that works wherever a script tag works.

#Do I need server-side GTM for the pixel to work?

No. Client-side GTM is sufficient for the JavaScript pixel. Server-side GTM is an optional companion that lets you also send the same events from your backend via the OpenAI Conversions API. Server-side helps recover conversions lost to ad blockers, browser tracking prevention, and consent declines. The pixel and the Conversions API share an event_id so OpenAI can deduplicate browser and server events as a single conversion.

#Where should I place the pixel snippet in my GTM container?

Use a Custom HTML tag wired to the built-in Initialization - All Pages trigger so the SDK loads on every page, as early as Tag Manager allows. The pixel needs early access to the page so it can capture the oppref query parameter from ChatGPT ad clicks before the user navigates away. If you have other tags that fire conversion events (lead form submit, order confirmation, custom DataLayer pushes), use GTM's built-in "Fire a tag before this tag fires" tag-sequencing to guarantee the pixel Init runs before any Event tag references the oaiq global.

Yes, but a manual Custom HTML tag has no consent checks of its own, so you set them up. In the tag's consent settings, require ad_storage (and ad_user_data if you pass customer data), so Tag Manager holds the pixel back until your consent banner reports consent. Then handle withdrawals with OpenAI's own consent command: oaiq("consent", false) stops measurement and removes the pixel's two cookies, which blocking the tag alone does not do, and oaiq("consent", true) turns it back on. Events blocked while consent is off are not sent later. Stape's gallery template and our B2B template read Consent Mode for you; OpenAI's official template does not. For GDPR or CPRA-regulated traffic, set this up before publishing the tag to production.

#How do I deduplicate browser-fired and server-fired conversion events?

Generate a unique event_id on your server when the conversion happens, pass it to the browser pixel via oaiq("measure", eventName, eventProps, { event_id }), and send the same event_id with the Conversions API call from your server. OpenAI matches on the tuple of pixel ID, event name, and event_id (plus custom_event_name for custom events) and collapses duplicates into a single conversion at ingest. The full deduplication pattern lives in our deeper post on ChatGPT Ads conversion tracking.

#How do I verify the ChatGPT Ads pixel is firing correctly?

Use GTM Preview mode. Open your container in Preview, load a page that should fire the pixel, and confirm the Custom HTML tag fired on the Initialization - All Pages trigger. Then open your browser's Network tab and look for the request to OpenAI's pixel endpoint returning a 200. To confirm click attribution, append a test oppref query parameter to your landing-page URL and check that the oaiq global captures it before navigation. For a conversion event, trigger the action (a form submit or purchase) and verify a second oaiq("measure") call fires with your event name. If the tag fires but no network request appears, a consent gate or an ad blocker is suppressing it. The most conclusive check is Ads Manager's Event Stream, which lists recent events as OpenAI received them.

Kevin O'Connell
Kevin O'Connell
Founder & AEO Consultant, AI-Advisors.ai

20-year B2B SaaS marketer. 3x Head of Marketing. One company exit (Sapling HR acquired by Kallidus, 2021). Now building AI-Advisors.ai to give mid-market B2B teams the AI visibility tools enterprise brands get. Writing about Answer Engine Optimization, ChatGPT Ads, Microsoft Copilot SEO, and the 5 A's of AI Marketing framework.

✦

Start tracking your AI visibility today

Install the tracking snippet, run your first audit, and see how AI platforms treat your brand. Start your 14-day free trial.

Get Started Free

Keep Reading

AI Ads
ChatGPT Ads Getting No Impressions? How to Find and Fix the Cause
10 min read
AI Ads
How to Set Up ChatGPT Ads Custom Audiences for B2B (Start With Exclusions)
10 min read
AI Ads
How to Set Up a ChatGPT Ads Conversion Campaign for B2B
10 min read