Support for Vercel is experimental. We strongly recommend testing it out in your preview
environment first.
- Add the
subtrace-nextpackage to your app:
- Import the package at the top-level:
- Add instrumentation to trace incoming requests. In your route.ts files, wrap your route handlers with the
tracefunction:
- Add the
SUBTRACE_TOKENenvironment variable to your preview/production environments on Vercel:

- Deploy your app as you normally would (eg: with
vercel deploy)