Skip to content
Docs

Always-on Tracing

With always-on tracing, Vercel continuously collects traces from your production and preview traffic, so you can debug real requests without reproducing them first. You control how much data is collected with sampling rules you set per project.

Always-on tracing is available in Beta on Enterprise, Pro, and Hobby plans

Always-on tracing captures traces from real traffic in the background, unlike session tracing, which only captures requests from your own browser session. Because the traces are already collected, you don't have to reproduce a problem to investigate it.

Use always-on tracing to:

  • Debug production issues after they happen, using traces that were already collected.
  • Catch rare or intermittent errors that you can't reliably reproduce.
  • Monitor performance across real user traffic, not just your own session.
  • Control how many traces you collect with sampling rules that target specific environments and paths.
  • A Vercel project deployed to production or preview.
  • Permission to update the project. Managing sampling rules requires a role with project update access. See team-level roles.

Always-on tracing captures infrastructure and outbound fetch spans automatically. To also capture framework and custom spans, instrument your application with @vercel/otel. Once instrumented, Next.js 13.4+ contributes framework spans for routes and rendering automatically.

You turn on always-on tracing by adding at least one sampling rule with a rate above 0%. Vercel starts collecting traces as soon as you save it.

You can configure sampling rules from two places in the dashboard:

  • Project settings: Select your team and project, then go to Settings → Tracing.
  • Logs page: Select your team and project, then open Logs in the sidebar. In the search bar, select the settings icon next to the tracing filter icon.

To add a rule:

  1. Open the tracing configuration from either entry point above.
  2. Select Add Sampling Rule.
  3. Choose the Environment to sample: All Environments, Production, or Preview.
  4. Set the Rate, the percentage of matching requests to trace, from 0 to 100%. A rate of 0% matches requests but collects nothing.
  5. (Optional) Enter a Request Path Prefix to apply the rule only to matching paths, such as /api. Leave it blank to match every path.
  6. Select Save.

To sample different environments or paths at different rates, add more rules. You can add up to 10 rules per project. Because the first matching rule wins and new rules are added to the bottom, add a rule with a 0% rate before a broader rule to exclude matching requests, such as a 0% rule on /health. To learn how overlapping rules are resolved and how sampling works, see Sampling.

To collect fewer traces, lower the sampling Rate or narrow rules with a Request Path Prefix. To turn off always-on tracing, remove all sampling rules and save. With no rules, Vercel stops collecting production and preview traces for the project.

You can also read and write the same rules from the terminal with vercel traces config. The CLI accepts rates from 1 to 100%, so a 0% rule has to be added from the dashboard.

Once always-on tracing is collecting data, view your traces in the dashboard:

  1. Select your team and project, then open Logs in the sidebar.
  2. Use the tracing icon in the filter bar to filter to traces.
  3. Find a request and select Trace to open its spans.

The trace timeline shows the spans and their durations:

Trace timeline showing spans for a request.
Trace timeline showing spans for a request.
Trace timeline showing spans for a request.
Trace timeline showing spans for a request.

For the full walkthrough, including the timeline, tree, and waterfall layouts, see Viewing traces in the dashboard.

You can also inspect a single trace from the terminal with vercel traces get <request-id>, using the request ID from a log line.

During Beta, always-on tracing usage is measured in span units for spans indexed after sampling.

PlanBeta pricing
Hobby1 million span units included per month
Pro$0.50 per 1 million span units
EnterpriseStarting at $0.50 per 1 million span units

An indexed span up to 2 KB counts as one span unit. Larger spans count in additional 2 KB increments. For example, a 3 KB span counts as two span units, and a 5 KB span counts as three.

During Beta, collected traces are retained for these periods:

PlanRetention
Hobby1 hour
Pro1 day
Enterprise3 days

Always-on tracing follows the shared Tracing limitations.

Last updated August 24, 2026

Was this helpful?

supported.