Getting Started
Introduction
Learn what @lutejka/nuxt-otel is and when to use it
@lutejka/nuxt-otel helps you gain deep observability into your Nuxt application with minimal effort.
What is @lutejka/nuxt-otel?
A Nuxt module that leverages Node.js Diagnostic Channels to automatically create OpenTelemetry spans for key Nuxt internals — renders, API requests, server route handling, and storage operations.
Instrumenting Nuxt applications with OpenTelemetry traditionally requires manual span creation and context management. This module eliminates that overhead by hooking into the native diagnostic channels that Nuxt and its ecosystem already emit.
What you can do
- Trace Nuxt renders automatically — SSR renders, island components, data fetching, and plugin initialization
- Instrument H3 requests — HTTP requests with method, URL, and status code attributes
- Monitor server routes — Custom route and middleware handling with proper context propagation
- Track storage operations — Unstorage get, set, remove, and other operations
- Add custom spans — Use
useOtelTracerfor manual instrumentation in your server routes - Emit structured logs — Use
useOtelLoggerfor OpenTelemetry-compatible log records - Browse telemetry live — DevTools UI at
/__nuxt-otelwith waterfall timelines - Query via MCP — Expose telemetry to AI agents through Model Context Protocol
When to use @lutejka/nuxt-otel
Use this module when you need to:
- Understand application performance bottlenecks in production
- Trace requests across Nuxt SSR and API boundaries
- Debug server-side rendering issues with detailed span information
- Integrate with existing OpenTelemetry infrastructure (collectors, backends)
- Provide AI coding assistants with real-time observability data via MCP
This documentation includes AI integration with MCP server and automatic
llms.txt generation.