Trace Context
The standard way of passing a trace identifier and parent span identifier from one service to the next, usually in the traceparent header.
In more detail
The W3C Trace Context standard carries the trace ID and the caller's span ID in the traceparent header. A receiving service creates a child span under that parent; if no valid context arrives, it starts a new trace.
Example
OpenTelemetry in Next.js propagates these headers on outgoing fetch calls.Related terms
- trace — A record of one request’s whole journey through a system, made of nested spans that show where the time went.
- span — One timed operation within a trace, such as handling a request or running a query, with its start, duration and attributes.
- traceparent — The HTTP header defined by Trace Context that carries the trace identifier, parent span identifier and sampling flag between services.
- correlation ID — A unique value attached to one request and passed along everywhere it goes, so its logs and traces can be found together.
- distributed tracing — Following one request across every service, queue and database it touches by recording linked spans that share a trace identifier.
- W3C — The World Wide Web Consortium, a standards body that publishes web standards such as CSS, XML, WCAG and Trace Context.
- OpenTelemetry — A vendor-neutral, open-source standard and set of tools for producing traces, metrics and logs and sending them to any backend.
- trace ID — An identifier shared by every span and log line belonging to one request, so they can be found together.
- span ID — A unique identifier for one span; each child span records its parent's span ID so the tree can be rebuilt.
Taught in
- Observability: Logs, Metrics, Traces — Modern API Architecture: REST, GraphQL & gRPC
- Distributed Tracing: OpenTelemetry & Traceparent — Production Full-Stack Engineering
- Full-Stack System Verification: Capstone Integration — Production Full-Stack Engineering
- Instrumentation: OpenTelemetry & Performance Spans — Next.js 15 & Modern App Router Architecture
- Traces, Spans And Context Propagation — Full-Stack Observability: Metrics, Tracing & Logging
- Fifteen Traces For Six Bookings: Where Context Was Lost — OpenTelemetry Certified Associate (OTCA) Exam Prep
- Traces From A Script Nobody Touched: Instrumentation Approaches — OpenTelemetry Certified Associate (OTCA) Exam Prep
- A Library That Traces Nothing, Safely: API, SDK And Extension — OpenTelemetry Certified Associate (OTCA) Exam Prep
- Fifty Two Spans, Four Requests: The Trace Data Model — OpenTelemetry Certified Associate (OTCA) Exam Prep
- Keep Your Logger: The Logs Bridge And Log Records — OpenTelemetry Certified Associate (OTCA) Exam Prep
- Fifty Five Characters: Trace Context And Baggage — OpenTelemetry Certified Associate (OTCA) Exam Prep
- Six Out Of Twelve At One In Four: Samplers — OpenTelemetry Certified Associate (OTCA) Exam Prep
- Nine Lines, Five Bugs: Configuring The SDK — OpenTelemetry Certified Associate (OTCA) Exam Prep
- Six Launches, No Code Changes: Language Agents — OpenTelemetry Certified Associate (OTCA) Exam Prep
- API And SDK Sprint: Fourteen Predictions — OpenTelemetry Certified Associate (OTCA) Exam Prep
- Which Node Was It? Collector Deployment Patterns — OpenTelemetry Certified Associate (OTCA) Exam Prep
- Maintenance Sprint: Symptoms First — OpenTelemetry Certified Associate (OTCA) Exam Prep
- Forty Four Of Sixty: The Mock And What It Tells You — OpenTelemetry Certified Associate (OTCA) Exam Prep
- The Evening Before: Final Review — OpenTelemetry Certified Associate (OTCA) Exam Prep