From 38507af6de354174ffb0e5972e0faf12bf90be6b Mon Sep 17 00:00:00 2001 From: Steven Eubank Date: Fri, 7 Aug 2026 17:44:13 +0200 Subject: [PATCH 1/3] docs(supabase): add client-side trace propagation cross-links Link Sentry's Supabase integration docs to the new Supabase client-side tracing feature. Adds a Trace Propagation section to the JS integration, a log correlation section to the Log Drains page, and new stub pages for Apple and Dart pointing to supabase.com/docs/guides/monitoring-and-debugging/client-side-tracing. Python docs are pending. --- docs/platforms/apple/common/integrations/supabase.mdx | 11 +++++++++++ docs/platforms/dart/common/integrations/supabase.mdx | 11 +++++++++++ .../common/configuration/integrations/supabase.mdx | 8 ++++++++ docs/product/drains/supabase.mdx | 10 ++++++++++ 4 files changed, 40 insertions(+) create mode 100644 docs/platforms/apple/common/integrations/supabase.mdx create mode 100644 docs/platforms/dart/common/integrations/supabase.mdx diff --git a/docs/platforms/apple/common/integrations/supabase.mdx b/docs/platforms/apple/common/integrations/supabase.mdx new file mode 100644 index 0000000000000..4bcec18881bf7 --- /dev/null +++ b/docs/platforms/apple/common/integrations/supabase.mdx @@ -0,0 +1,11 @@ +--- +title: Supabase +description: "Correlate Sentry traces with Supabase logs on Apple platforms." +sidebar_order: 50 +--- + +The Sentry Apple SDK instruments URLSession and automatically injects `sentry-trace` and `baggage` headers into outgoing requests — including those made by the Supabase Swift SDK. Enabling `enablePropagateTraceparent` also adds the W3C `traceparent` header, which Supabase reads to stamp API Gateway and Edge Function logs with your trace ID. + +Combined with [Supabase Log Drains](/product/drains/supabase/), this lets you navigate from a Sentry span directly to the Supabase server logs it produced — with no changes to your `SupabaseClient` setup. + +See the [Supabase Swift trace propagation documentation](https://supabase.com/docs/guides/monitoring-and-debugging/client-side-tracing) for full setup instructions, including the SwiftPM `OpenTelemetry` trait and `enablePropagateTraceparent` configuration. diff --git a/docs/platforms/dart/common/integrations/supabase.mdx b/docs/platforms/dart/common/integrations/supabase.mdx new file mode 100644 index 0000000000000..15b99cc37b4ea --- /dev/null +++ b/docs/platforms/dart/common/integrations/supabase.mdx @@ -0,0 +1,11 @@ +--- +title: Supabase +description: "Correlate Sentry traces with Supabase logs in Dart and Flutter apps." +sidebar_order: 35 +--- + +The Sentry Flutter/Dart SDK can propagate W3C trace context through Supabase API requests. Enabling `propagateTraceparent` (requires `sentry_flutter` ≥9.7.0) attaches the `traceparent` header to outgoing HTTP requests, which Supabase reads to stamp API Gateway and Edge Function logs with your trace ID. + +Combined with [Supabase Log Drains](/product/drains/supabase/), this lets you navigate from a Sentry span directly to the Supabase server logs it produced. + +See the [Supabase Dart trace propagation documentation](https://supabase.com/docs/guides/monitoring-and-debugging/client-side-tracing) for full setup instructions, including the `TracePropagationOptions` API. diff --git a/docs/platforms/javascript/common/configuration/integrations/supabase.mdx b/docs/platforms/javascript/common/configuration/integrations/supabase.mdx index f33cf94112439..e9f6ce5de7339 100644 --- a/docs/platforms/javascript/common/configuration/integrations/supabase.mdx +++ b/docs/platforms/javascript/common/configuration/integrations/supabase.mdx @@ -110,3 +110,11 @@ The integration automatically: ## Supported Versions - `@supabase/supabase-js`: `>=2.0.0` + +## Trace Propagation + +Starting with `@supabase/supabase-js` version `2.106.0`, the Supabase client can propagate W3C trace context (`traceparent`) through Supabase services. Because `Sentry.init()` already registers a W3C-compliant OpenTelemetry provider, no additional OTel setup is needed — just add `tracePropagation: true` to your `createClient` call. + +The `trace_id` from a Sentry span then flows into Supabase API Gateway and Edge Function logs. Combined with [Supabase Log Drains](/product/drains/supabase/), this lets you navigate from a Sentry span directly to the server-side logs it produced. + +See the [Supabase client-side tracing documentation](https://supabase.com/docs/guides/monitoring-and-debugging/client-side-tracing) for full setup instructions. diff --git a/docs/product/drains/supabase.mdx b/docs/product/drains/supabase.mdx index 07265811be566..e369bae820024 100644 --- a/docs/product/drains/supabase.mdx +++ b/docs/product/drains/supabase.mdx @@ -33,3 +33,13 @@ ___DSN___ 2. Create a Sentry log drain in the [Supabase dashboard](https://supabase.com/dashboard/project/_/settings/log-drains). Make sure you provide the DSN you grabbed in the previous step. Then you should get logs in your Sentry project. All fields from the log event are attached as attributes to the Sentry log, which can be used for filtering and grouping in the Sentry UI. + +## Correlating Logs with Sentry Traces + +If you enable [client-side trace propagation](https://supabase.com/docs/guides/monitoring-and-debugging/client-side-tracing) in the Supabase SDK, the `trace_id` in forwarded logs will match the Sentry trace that triggered the request. This lets you navigate from a Sentry span directly to the Supabase server logs it produced. + +Setup instructions by platform: + +- **JavaScript**: [Supabase JavaScript integration](/platforms/javascript/configuration/integrations/supabase/#trace-propagation) +- **Swift**: [Supabase Swift integration](/platforms/apple/integrations/supabase/) +- **Flutter/Dart**: [Supabase Dart integration](/platforms/dart/integrations/supabase/) From 06afa13b5255705e90ef1594dbfb853af0fa91d4 Mon Sep 17 00:00:00 2001 From: Steven Eubank Date: Tue, 11 Aug 2026 15:58:31 +0200 Subject: [PATCH 2/3] fixes this was wrong my colleague confirmed: "that's wrong. I verified against sentry-javascript source: Sentry's OTel propagator does **not** emit traceparent unless you also set propagateTraceparent: true in Sentry.init() . It defaults to false. Without it, a user following this doc gets zero trace headers on Supabase calls, silently. For the browser SDK there's a second gap: Sentry only attaches headers to cross-origin requests for hosts listed in tracePropagationTargets, and Supabase is always cross-origin, so the project's Supabase URL needs to be in that list too." --- .../javascript/common/configuration/integrations/supabase.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/platforms/javascript/common/configuration/integrations/supabase.mdx b/docs/platforms/javascript/common/configuration/integrations/supabase.mdx index e9f6ce5de7339..02cb262a8e9a8 100644 --- a/docs/platforms/javascript/common/configuration/integrations/supabase.mdx +++ b/docs/platforms/javascript/common/configuration/integrations/supabase.mdx @@ -113,7 +113,7 @@ The integration automatically: ## Trace Propagation -Starting with `@supabase/supabase-js` version `2.106.0`, the Supabase client can propagate W3C trace context (`traceparent`) through Supabase services. Because `Sentry.init()` already registers a W3C-compliant OpenTelemetry provider, no additional OTel setup is needed — just add `tracePropagation: true` to your `createClient` call. +Starting with `@supabase/supabase-js` version `2.106.0`, the Supabase client can propagate W3C trace context (`traceparent`) through Supabase services. Because `Sentry.init()` already registers a W3C-compliant OpenTelemetry provider, add `tracePropagation: true` to your `createClient` call. You'll also need to set `propagateTraceparent: true` in `Sentry.init()` (it defaults to `false`) so Sentry actually emits the `traceparent` header. For browser apps, add your Supabase project URL to `tracePropagationTargets` in `Sentry.init()` as well — Sentry only attaches trace headers to cross-origin requests for listed targets, and Supabase is always cross-origin. The `trace_id` from a Sentry span then flows into Supabase API Gateway and Edge Function logs. Combined with [Supabase Log Drains](/product/drains/supabase/), this lets you navigate from a Sentry span directly to the server-side logs it produced. From 9414b178995dc47afc98eaa1738bbc7b6a943b0e Mon Sep 17 00:00:00 2001 From: Andrei Borza Date: Tue, 11 Aug 2026 17:02:52 +0200 Subject: [PATCH 3/3] Fix 404 link to the JavaScript Supabase integration page --- docs/product/drains/supabase.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/product/drains/supabase.mdx b/docs/product/drains/supabase.mdx index e369bae820024..bb74dd854c650 100644 --- a/docs/product/drains/supabase.mdx +++ b/docs/product/drains/supabase.mdx @@ -40,6 +40,6 @@ If you enable [client-side trace propagation](https://supabase.com/docs/guides/m Setup instructions by platform: -- **JavaScript**: [Supabase JavaScript integration](/platforms/javascript/configuration/integrations/supabase/#trace-propagation) +- **JavaScript**: [Supabase JavaScript integration](/platforms/javascript/guides/node/configuration/integrations/supabase/#trace-propagation) - **Swift**: [Supabase Swift integration](/platforms/apple/integrations/supabase/) - **Flutter/Dart**: [Supabase Dart integration](/platforms/dart/integrations/supabase/)