Skip to Content

Supabase

Send logs from your Supabase project to Everr with a Supabase log drain, and connect them to your app's traces. No code changes needed for the logs.

Sendslogs

This guide shows you how to send logs from your Supabase project to Everr. Supabase forwards the logs of its whole stack over OpenTelemetry (OTLP) through a log drain, so you add Everr as a drain and Supabase does the rest.

Once it's set up, you get:

  • Logs from Postgres, Auth, Storage, Edge Functions, and the rest of your project's services
  • The API gateway log of every request your app makes to Supabase
  • Optionally, the trace ID of your app's request on those logs, so you can find the Supabase logs of one request

Prerequisites

  • A Supabase project on the Pro, Team, or Enterprise plan. Log drains aren't available on Free.
  • An Everr API key with the Send telemetry capability (see Mint an API key)

Step 1. Add Everr as a log drain

In the Supabase dashboard, open your project's Project Settings > Log Drains, add a destination, and choose OpenTelemetry (OTLP):

FieldValue
Endpointhttps://ingest.everr.dev/v1/logs
Protocolhttp/protobuf
GzipOn
HeadersAuthorization: Bearer <your-api-key>

Save the drain. Supabase starts forwarding logs right away.

A drain belongs to one project. Add one to each project you want in Everr.

Validate

Use your app for a minute, then open Logs in Everr. You should see logs from your Supabase services, including one API gateway log for each request your app made.

Connect your traces to Supabase logs

Supabase doesn't send traces, but it reads the W3C traceparent header on incoming requests and writes the trace ID on its API gateway and Edge Function logs. If your app sends traces to Everr, pass its trace context to Supabase and you can open the Supabase logs of any request by filtering Logs by its trace ID.

From the browser

With @everr/otel-web, add your Supabase URL to tracePropagationTargets so the SDK adds traceparent to Supabase requests:

new WebSDK({
  serviceName: "acme-web",
  ingestKey: "<your-public-key>",
  instrumentations: [network({ tracePropagationTargets: [".supabase.co"] })],
});

Create the SDK before you call createClient, so the Supabase client uses the instrumented fetch.

If you call Edge Functions from the browser, their CORS response must allow the trace header. Add traceparent to the Access-Control-Allow-Headers your functions return, then redeploy them.

From a server

With an OpenTelemetry SDK on your server (see Any OpenTelemetry SDK), turn on trace propagation in supabase-js 2.112.0 or later:

import "@supabase/supabase-js/tracing";
import { createClient } from "@supabase/supabase-js";

const supabase = createClient(SUPABASE_URL, SUPABASE_KEY, {
  tracePropagation: true,
});

The tracing import must come first in your entry point. Requests made inside an active span then carry its trace context. See Supabase's client-side tracing guide for other languages and older supabase-js versions.

Control volume and cost

Log drains are a paid add-on in Supabase, and everything the project logs goes to the drain, so busy projects send a lot. See Supabase's log drain pricing.

Limitations

  • Logs only. Supabase doesn't export traces or metrics. Use your app's own instrumentation for traces, as above.