Attribute website payments with Stripe

Connect a customer-owned Stripe account to consenting website journeys with read-only access.

Last updated November 30, 2026

Connect your own Stripe account to record supported website payments and refunds in Attribution. This connection reads payment information. It cannot create a charge, issue a refund, change a subscription or move money. It is separate from your AEO Goal subscription and does not use Stripe Connect.

Before you start

  • The brand owner must complete setup. Select the correct brand first.
  • Install Site Tracking, verify that visits arrive, and obtain analytics consent.
  • Your checkout developer must attach the consenting visitor metadata described below to the canonical Stripe PaymentIntent.
  • EUR and USD are currently supported. Payments without the required visitor, consent and site metadata cannot be attributed.

Choose one payment source

Open Site Tracking → Connections. Above Connected stores or Stripe payments, the Payment source control shows the current choice. Choose Use stripe payments for this brand, review the confirmation and choose Confirm payment source.

A brand chooses Browser tracking, Connected stores or Stripe payments as its authoritative source for browser and connected-processor purchases and refunds. Native sources disable browser purchase/refund events; leads and signups are unaffected. Offline sales remain separately owner-attested. This source policy does not deduplicate every possible owner-submitted offline record. Changing the choice is blocked by live browser/connected-payment history or accepted live receipts. Marked sandbox payments and outside-processor offline sales remain separate and do not block a safe setup change. A 409 means you need a controlled migration; contact support rather than deleting history or trying another account. You can choose Use connected stores for this brand or Use browser tracking for this brand under the same rules. Revoking a connection never changes the source automatically.

Set up Stripe payments

Choose Stripe payments in the connection selector, then Set up Stripe payments. The form has three steps.

1. Create a read-only restricted key

Choose Sandbox for testing or explicitly choose Live for customer payment attribution. Live mode imports real customer payment data; review your brand, account, consent handling and webhook mode before continuing. The restricted key, webhook destination and payment objects must all use the same mode.

Use a dedicated restricted API key, not an unrestricted sk_ key or a publishable key. A sandbox key starts with rk_test_; a live key starts with rk_live_. Enter your Stripe account ID (acct_…). Keep the restricted key in this secure form or your server’s secret manager; never paste it into chat, a tracking tag, browser source or metadata.

Find the account ID in Stripe’s Account settings or Personal details. For sandbox setup, use the account picker to Switch to sandbox, choose Manage sandboxes, then Open the intended sandbox. Confirm the sandbox banner before copying its account details or keys. See Stripe’s sandbox instructions.

The connector makes only these Stripe API reads:

Resource Required access API operation
Your own account Read GET /v1/account, to verify the supplied account ID
Events Read GET /v1/events/{id} and bounded GET /v1/events pages, to verify notifications and recover missed events
Payment Intents Read GET /v1/payment_intents/{id}, to read canonical payment and visitor metadata
Refunds Read GET /v1/refunds/{id}, to verify refund state

Leave unrelated resources at None and grant no Write permissions. The table describes the API reads required, rather than guaranteed Dashboard permission labels. If Stripe does not offer the necessary read access, stop and ask support to review the restricted-key configuration; do not substitute an unrestricted key. Webhook destinations are configured manually in your Stripe Dashboard; the key does not need permission to create them. No connected-account, payout, customer, subscription or payment-creation access is required.

2. Add the webhook

After entering the account, restricted key and mode, confirm your review and choose Prepare Stripe webhook. This verifies and stores the key encrypted, then gives you an inactive connection and its webhook URL. Copy that URL. In Stripe Workbench, create a webhook event destination for your account in the selected mode. Use snapshot events and select exactly:

  • payment_intent.succeeded
  • refund.created
  • refund.updated

Paste the URL into Stripe, then copy that destination’s signing secret (whsec_…) into Webhook signing secret. This is a separate credential from the restricted API key. A signing secret from another endpoint or mode will not work. Do not register every event type; Checkout or Invoice notifications do not create additional purchases here.

3. Connect and verify

Once the webhook is configured, confirm I reviewed this brand, Stripe account and Sandbox/Live mode, then choose Connect Stripe sandbox or Connect Stripe live. Secret fields clear when submitted. Switching brands closes the setup and clears its fields and results.

Use a consented sandbox website journey first. Complete a sandbox payment through your own checkout, then choose Refresh Stripe status. The account verification time confirms the account read; the last authenticated notification time confirms receipt of a verified notification. Neither alone proves a conversion was recorded. Check durable delivery status and the Attribution report before calling the connection verified. Sandbox activity is not evidence of a live customer payment. Sandbox receipts carry a Sandbox · excluded from ad exports badge. Sandbox payments are excluded from the default Attribution overview, advertising economics and AI report, and are never included in ad exports.

To preview them, explicitly check Include sandbox payments in the Attribution overview/economics or the Site Tracking AI report. The warning identifies these as test-inclusive totals, not live financial results. The checkbox starts unchecked. This preview does not enable sandbox ad delivery.

To move from Sandbox to Live, first Revoke Stripe access, then prepare a new Live connection and register its webhook. Account and mode are locked while a connection is active. Sandbox-only financial history and receipts can permit this change; real financial history requires a controlled migration. Old sandbox receipts cannot be recovered into a Live connection.

Developer instructions: visitor metadata

After analytics consent, call aeo('visitorId') in your website. It returns null when no consenting visitor is available. Send the non-null ID to your own checkout server. Your server must validate consent and the selected website, then attach these string metadata fields to the canonical PaymentIntent:

{
  "aeo_visitor_id": "<consented visitor ID>",
  "aeo_analytics_consent": "true",
  "aeo_site_key": "<this brand's public Site Tracking key>"
}

For Stripe Checkout, attach these through payment_intent_data.metadata in your existing server-side checkout creation. Session metadata alone does not populate the PaymentIntent. See Stripe’s metadata guidance. The connector does not create or modify your checkout.

Never send names, emails, phone numbers, authentication tokens or secret keys as these values. AEO Goal checks the canonical site’s public tracking key to route payments to the correct brand; it does not assign all account revenue to a brand or guess a visitor from customer contact information.

Check durable delivery status

Expand Payment delivery and recovery in the Stripe card.

The Stripe delivery inbox shows only this brand’s retained Stripe receipts. Totals include all retained Stripe receipts; the list shows the newest 50. Unresolved encrypted receipts remain retained until resolved or erased. Each automatic processing window lasts seven days, with at most 24 attempts before human-reviewed redrive is needed. Completed receipt metadata has bounded cleanup; this inbox is not a Stripe order archive. Recorded means the ledger accepted the conversion. Pending, running and retrying mean processing is incomplete. Blocked requires restoring access; failed is a dead letter requiring review. Erasure-suppressed receipts cannot be replayed.

The owner can choose Retry Stripe delivery for an eligible receipt. A queued retry is not a recorded conversion: refresh delivery status to check the result. An eligible retry can renew an ended automatic window without resetting attempts or changing the original receipt or canonical Stripe event time. After repairing the cause, use Redrive after repair, choose Quota restored, Credentials repaired or Service repaired under Repair completed, then Confirm redrive. This audited owner action resets attempts and renews the seven-day window. It preserves Sandbox/QA provenance and cannot restore erased receipts, bypass current access or replace revoked-connection recovery. See store delivery recovery for shared inbox limits. Revoked credentials do not resume automatically after reconnecting. The owner can choose Recover receipts from revoked connections, review the current account and Sandbox/Live mode, then Confirm receipt recovery. The server re-verifies the account and mode, then rebinds up to 100 eligible retained receipts from revoked connections for that same account and mode. Receipts below the attempt limit can queue for processing; an ended window is renewed without changing receipt time or resetting attempts. Exhausted receipts remain failed and need Redrive after repair in the inbox before processing can resume. Recovery does not restore revoked credentials or replay erased or completed receipts; Sandbox receipts cannot be rebound to a Live connection.

The result separates receipts queued from rebound receipts that still require Redrive after repair, and shows eligible receipts remaining and the batch limit. If receipts remain, review and confirm another batch. The existing worker processes the queue; check the inbox for recorded status afterward.

Recover missed notifications

Under Payment delivery and recovery, the brand owner can choose Reconcile last 7 days, review the scope, then Read Stripe events. Each click reads up to five supported events from a fixed seven-day window and submits verified conversions to the durable inbox. The result shows this page’s scanned, recorded, queued, ignored and dead-letter counts. These are page outcomes, not totals for your Stripe account.

Choose Read next page when more events remain. If a read is interrupted, choose Retry remaining events; do not assume the review completed. Cursors expire after one hour, at which point start a new review. No more pages in this review window means that review has no remaining pages; queued receipts can still need processing. Recovery does not import all historical account revenue.

Troubleshooting and access

  • No notifications: check the exact URL, required event types, destination mode and signing secret. Check Site Tracking and the selected source too.
  • No attributed payment: check consent and all three canonical PaymentIntent metadata fields. Verify the currency and durable delivery status.
  • Access unavailable: the brand owner should review read permissions and account/mode matching. Do not grant broad write permissions to bypass an error.
  • Change needs review: existing history, receipts or a conflicting connection can require a controlled migration. Refresh and contact support.
  • Temporary failure: refresh status and retry later. Do not replace the key repeatedly or assume an accepted notification is already recorded.

Choose Revoke Stripe access and confirm to stop new notifications and queued processing locally. Remove the dedicated restricted key and webhook destination in Stripe separately. Revocation retains recorded history and the selected payment source; use the product’s privacy controls for erasure.