OpenAI Ad Tracking: How the __obi Cookie Links ChatGPT Accounts to External Web Activity

OpenAI implements third-party tracking to link ChatGPT accounts to external web activity

OpenAI has deployed an advertising tracking mechanism that allows it to connect a user's activity on third-party websites to their specific ChatGPT account. By using a specialized cookie called __obi, OpenAI can track products users search for, articles they read, and their purchase behaviors on any site that has installed the OpenAI measurement pixel.

Technical Mechanism: The __obi Cookie Lifecycle

OpenAI's tracking system operates through a three-step process that binds a user's identity to a cross-site identifier.

1. Identity Binding and Token Generation

When a user visits chatgpt.com, the client generates 16 random bytes and requests a sync token from the backend via /backend-api/bazaar/obi/sync-token. The server returns an RS256 JWT (JSON Web Token) that binds the user's account subject (sub) to a unique identifier (obi). This token is short-lived, expiring in 60 seconds.

2. Cross-Site Cookie Deployment

The client then sends this JWT to bzr.openai.com/v1/obi/sync. The server responds by setting a cookie named __obi scoped to the .openai.com domain. Crucially, this cookie is configured with SameSite=none and Secure, which are the specific settings required for a browser to send the cookie during cross-site requests (third-party requests).

3. Third-Party Data Transmission

When a user visits an advertiser's website that has installed the OpenAI SDK (the measurement pixel), the browser automatically attaches the __obi cookie to requests sent to OpenAI's hosts (such as bzrcdn.openai.com or bzr.openai.com). This happens even during the initial script load of the SDK, meaning the user's identity is disclosed to OpenAI before any of the SDK's internal code even executes.

Data Collection and Identity Scraping

Beyond the __obi identifier, the OpenAI SDK collects identity data directly from the advertiser's page using several methods:

  • Scraped Identity: The SDK scrapes data from form fields, rendered page text, and the tag-manager bus (e.g., window.dataLayer.push or adobeDataLayer). In observed traffic, scraped identity events outnumbered advertiser-supplied identity events 685 to 255.
  • Hashed PII: Email addresses, phone numbers, and names are SHA-256 hashed before transmission.
  • Cleartext Data: Geographic data, including country, region, city, and postal code, is sent in cleartext. Postal codes were among the most frequently harvested form fields.
  • Behavioral Data: URLs are sent as origin plus path. Observed paths included sensitive information such as medical conditions, debt-solution funnels, and litigation intake forms.

Scope and Limitations

Browser Compatibility

The tracking mechanism relies on third-party cookies. Consequently, it does not work on browsers that block them by default, such as Safari (via Intelligent Tracking Prevention) or any browser on iOS. It is primarily observed on Chrome for Android.

Consent and Policy

OpenAI's cookie policy classifies __obi as an "Analytics" cookie. However, the tracking occurs even for users who grant analytics consent but refuse marketing consent, as the __obi cookie is tied to the analytics_allowed decision in the sync token.

User Visibility

Advertisers cannot see the __obi cookie because it belongs to the .openai.com domain, which is third-party to the advertiser's site. Advertisers only see conversion events; they do not know which specific ChatGPT user is visiting their site.

Community Perspectives and Privacy Concerns

Technical discussions on Hacker News highlight a significant tension between standard ad-tech practices and the nature of AI products.

"The mechanism is standard adtech. What has no precedent is running it on an AI chat product. People tell these products things they would not put on a social network, and these products increasingly act on their behalf."

Critics argue that the expectations of privacy for a conversational AI are fundamentally different from those of a social network like Facebook. Some users expressed concern that this data collection could lead to "grotesquely biased" AI responses designed to sell products rather than provide neutral information.

Other users noted that for those using browsers with strict cookie partitioning (such as Firefox or Brave), the privacy concern is largely mitigated as the cookie jars are kept separate, preventing the account from being linked to third-party ad views.

Sources

Related