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.
- Open your published site (custom code does not run in the Framer canvas preview) in a private (incognito) window.
- Open developer tools (F12), go to the Network tab and filter by
bzr.openai.com. - 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 atype. You should seepage_viewed(or another event your site sends on page load). Types starting withopenai::oroai::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). - 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.
- 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 byoaiq.min.jsand 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.
-
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_dataandad_personalization. - Reload after clicking Accept: the banner should not come back.
-
Check that GTM loads. Filter the Network tab by
googletagmanager.com: you should seegtm.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 nogtm.jsrequest, the GTM ID is empty or wrong, or the banner is missing from this page. -
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_storageset togranted, followed by an event namedcookie_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.
- that a consent update appears with
-
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_updateis 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_viewedtag two triggers: a Custom Event trigger forcookie_consent_updateand Initialization - All Pages. Keep thead_storageconsent 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 wantpage_viewedon later pages, add a separate tag with a History Change trigger and the samead_storageconsent requirement. - 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
-
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 forad_storage. - A Custom HTML tag that calls
oaiq("consent", false)must also calloaiq("consent", true)after Accept and sendpage_viewedagain afterwards. See the general guide.
- 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
-
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 sameoaiqon the page. OpenAI also says the pixel keeps consentfalsewhen it finds a stored denial, so a visitor (or you, while testing) who once rejected stays blocked until code callsoaiq("consent", true). -
Look at the Console for errors. A script error in custom code before a
measurecall stops the event. If a Content Security Policy applies to your site, it must allow the sources OpenAI lists (https://bzrcdn.openai.comfor scripts,https://bzr.openai.comfor connections); the console shows a CSP violation otherwise. -
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
- In a fresh private window on the published site: no measurement events before Accept, and a
page_viewedevent within a few seconds after Accept, on the same page. - Reload the page as a returning visitor who already accepted:
page_viewedleaves without any click. - 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 channelpixel_sdk. - 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
- OpenAI Developers, Measurement Pixel (consent, stored denial, blocked events are not replayed, Content Security Policy sources, debug option): https://developers.openai.com/ads/measurement-pixel
- OpenAI Developers, Conversion Tracking (Monitoring Events,
pixel_sdkchannel): https://developers.openai.com/ads/conversion-tracking - OpenAI on GitHub, Ads Measurement Pixel GTM template (“Send a measurement event when this tag fires”, base tag that only initializes the pixel, no consent call): https://github.com/openai/ads-measurement-pixel-gtm-template
- Stape, OpenAI Ads Pixel tag for web GTM (third-party; Consent Granted, GTM consent mode support): https://stape.io/helpdesk/documentation/openai-ads-pixel-tag
- Framer Help, Add Google Tag Manager to your site (Site Settings > Code, Initialization - All Pages, Preview and Tag Assistant Companion): https://www.framer.com/help/articles/how-to-add-google-tag-manager-to-your-site/
- Framer Academy, Custom Code (page-level custom code; custom code does not run in the canvas preview): https://www.framer.com/academy/lessons/custom-code
- Framer Academy, Add a Cookie Banner to your site in Framer: https://www.framer.com/academy/lessons/cookie-banner-component
- Framer Updates, Cookie Banner component: https://www.framer.com/updates/cookie-banner-component
- Sourcepeak Studio, Framer Cookie Banner & Google Tag Manager: common implementation mistakes (third-party guide;
cookie_consent_updateevent, GTM loaded by the component): https://sourcepeak.studio/blog/framer-cookie-banner-google-tag-manager-common-implementation-mistakes-to-avoid - Google Tag Manager Help, Tag Manager consent mode support: https://support.google.com/tagmanager/answer/10718549
- Google Tag Manager Help, History change trigger (fires on URL fragment changes and the HTML5 pushState API): https://support.google.com/tagmanager/answer/7679322
- IsPixelWorking live test, 2026-10-01: on a published Framer site with the Cookie Banner and a GTM ID, the data layer showed
consent defaultbefore Accept andconsent updatefollowed by acookie_consent_updateevent after Accept;gtm.jswas requested by Framer’s site script. Internal links changed pages with the History API, without a new page load.