Inspect Vercel log drain information and correlate it to tracing data.
Vercel's powerful front-end cloud accelerates and improves UI development. Projects hosted on Vercel natively generate logs and can generate tracing data through Vercel's @vercel/otel NPM package. You can fully leverage this data through Dash0.
Vercel's frontend cloud supports two types of telemetry: logs and traces. This guide will describe how to set up both, starting with logs, which is very easy thanks to Dash0's native Vercel integration.
In short, click the button below and follow the dialog.
Vercel has its own distribution of the OpenTelemetry SDK called @vercel/sdk
. It is fully compatible with the official
OpenTelemetry SDK, and adds helpful extensions.
If you are using a Next.js version <15
, you need to enable the Next.js instrumentation hook. Modify the file next.config.js
with the following settings:
Now you can initialize Vercel's OpenTelemetry SDK via a file called instrumentation.ts
(see documentation, located directly in your src/
folder). Add the following content:
As the last step, we need to tell the Next.js OpenTelemetry SDK where to send its data to, and how to authenticate. This can be achieved using the standardized OpenTelemetry headers and Vercel's environment variable support.
Distributed tracing data will now arrive from Vercel within Dash0!
For an implementation example, refer to our Next.js & Vercel example application on GitHub.