Fix guide · Framer · medium · about 30 min

OpenAI Pixel not firing after consent on Framer: how to fix

For the finding “OpenAI Pixel does not fire after consent”. Also for: Any website, Shopify, WordPress, Webflow.

What this means

The OpenAI Pixel (the ChatGPT Ads Measurement Pixel) is installed on your Framer site, but after cookies were accepted, no events were sent to OpenAI. As far as ChatGPT Ads can tell, this page has no visitors.

Why it costs you money:

  • ChatGPT Ads cannot see page views or conversions from this page, so reported conversions are too low and your cost per conversion looks worse than it is.
  • Conversion-optimized campaigns learn from these events. Without them, they optimize on little or nothing.

How sure we are: if our checker found and accepted your cookie banner, this is reported as critical. If we did not find a banner we could operate, it is reported as high: the pixel may be waiting for a banner we did not recognize. Test it yourself before changing anything.

How to confirm it yourself

Our check runs from a browser in the EU. Framer’s Cookie Banner has separate settings for EU visitors and for the rest of the world. In the banner component’s code, it decides which to use from the visitor’s browser time zone and language, not from the IP address. A VPN does not change it; to see the EU version, set your computer’s time zone to a European city before you test.

  1. Open your published site (custom code does not run in the Framer canvas preview) in a private (incognito) window.
  2. Open developer tools (F12), go to the Network tab and filter by bzr.openai.com.
  3. Click Accept on the cookie banner and wait about 5 seconds. Click the requests and look at the payload: it carries a list of events, each with a type. You should see page_viewed (or another event your site sends on page load). Types starting with openai:: or oai:: are the SDK’s own service messages and do not count (at the time of writing the SDK sends these on its own; OpenAI does not document them).
  4. If no measurement event appears, the pixel does not fire after consent. If events only start on a later page, the pixel starts one page too late, and you lose the landing page of every new visit, which is usually the page your ChatGPT ad points to.
  5. In the Console tab, type typeof oaiq. "undefined" means the pixel never loaded on this page (in a GTM setup: the OpenAI tag did not fire). "function" only means the snippet ran: it creates a queue before the SDK arrives, and OpenAI’s GTM template creates one too. Filter the Network tab by oaiq.min.js and check that the SDK itself loaded (status 200); if it did, the problem is in the consent or event calls.

How to fix

On a typical Framer setup, the chain is: Framer’s Cookie Banner component, then Google Consent Mode in Google Tag Manager (GTM), then the OpenAI tag in GTM. Check each link.

  1. Check the Cookie Banner component.

    • Its GTM ID property must contain your container ID, and it must be the same container that holds your OpenAI tag.
    • The component must be on every page, usually inside the navigation or footer. If it only exists on the home page, visitors who land elsewhere never see it and never send a consent update.
    • Under Regions, Marketing must be part of what the visitor accepts. In the banner component’s code, Marketing maps to ad_storage, ad_user_data and ad_personalization.
    • Reload after clicking Accept: the banner should not come back.
  2. Check that GTM loads. Filter the Network tab by googletagmanager.com: you should see gtm.js?id=GTM-... with your container ID. The Cookie Banner loads GTM itself when GTM ID is filled in, so you do not need a GTM snippet in custom code. If there is no gtm.js request, the GTM ID is empty or wrong, or the banner is missing from this page.

  3. Use GTM Preview mode. In GTM, click Preview, enter your published Framer address and click Accept on the banner. (Framer notes that Preview needs your latest changes published; the Tag Assistant Companion extension can help if it does not connect.) Check:

    • that a consent update appears with ad_storage set to granted, followed by an event named cookie_consent_update;
    • what happened to the OpenAI tag. Blocked by consent means the consent update did not arrive or does not grant ad_storage. Not fired at all means its trigger never ran.
  4. Fix the trigger. In our tests, Framer’s banner talks to GTM like this:

    • First visit: the banner sets the default consent (usually denied), then loads GTM. When the visitor clicks Accept, it sends a consent update and pushes cookie_consent_update.
    • Later visits: the stored choice is applied before GTM loads, and no cookie_consent_update is sent.

    A tag with only an Initialization or page view trigger is blocked on the first visit and never runs again on that page. GTM does not fire a tag blocked by consent later by itself, so nothing reaches OpenAI (and OpenAI’s pixel does not replay events blocked by its own consent command either). Give the page_viewed tag two triggers: a Custom Event trigger for cookie_consent_update and Initialization - All Pages. Keep the ad_storage consent requirement and set the firing option to Once per page. Framer changes pages without a full page reload, and GTM’s page load triggers do not run on those changes; if you also want page_viewed on later pages, add a separate tag with a History Change trigger and the same ad_storage consent requirement.

  5. Check the tag itself.

    • OpenAI’s template (OpenAI Ads Measurement Pixel): the tag must have Send a measurement event when this tag fires ticked and an Event name such as page_viewed. With that box cleared, the tag only loads and initializes the pixel and sends no event. Check that the Pixel ID is the one from your Ads Manager.
    • Stape’s OpenAI Ads Pixel template (third-party): if Consent Granted is false, the tag holds events until it fires again with consent granted. With Enable GTM consent mode support, it waits for ad_storage.
    • A Custom HTML tag that calls oaiq("consent", false) must also call oaiq("consent", true) after Accept and send page_viewed again afterwards. See the general guide.
  6. Look for a leftover copy in custom code. Check Site Settings > Code and each page’s own custom code. An old snippet that calls oaiq("consent", false) on every page also switches off the pixel your GTM tag uses, because both share the same oaiq on the page. OpenAI also says the pixel keeps consent false when it finds a stored denial, so a visitor (or you, while testing) who once rejected stays blocked until code calls oaiq("consent", true).

  7. Look at the Console for errors. A script error in custom code before a measure call stops the event. If a Content Security Policy applies to your site, it must allow the sources OpenAI lists (https://bzrcdn.openai.com for scripts, https://bzr.openai.com for connections); the console shows a CSP violation otherwise.

  8. Publish both the GTM container and the Framer site.

Common causes

  • The Cookie Banner points to a different GTM container from the one with the OpenAI tag (for example an old test container).
  • The OpenAI tag has only an Initialization or page view trigger, and no trigger for cookie_consent_update.
  • The Cookie Banner component is not on every page.
  • The tag requires a consent type that the banner never grants, for example because the banner’s marketing option is turned off.
  • The only OpenAI tag is a base tag with Send a measurement event when this tag fires cleared.
  • An old snippet in custom code calls oaiq("consent", false) on every page.
  • GTM changes were saved but not published, or the Framer site was not republished.

How to verify the fix

  1. In a fresh private window on the published site: no measurement events before Accept, and a page_viewed event within a few seconds after Accept, on the same page.
  2. Reload the page as a returning visitor who already accepted: page_viewed leaves without any click.
  3. If you have access to the Advertiser API, OpenAI’s recent-events endpoint (GET /v1/conversions/events?pid=<PIXEL-ID>) shows a sample of events from roughly the last 15 minutes; browser events show the channel pixel_sdk.
  4. Re-run the check on IsPixelWorking. The issue should be gone, and “OpenAI Pixel fires before cookie consent” should not appear in its place.

Sources

Guides for your consent tool