OpenTelemetry Go SDK
Official OpenTelemetry Go SDK for distributed tracing, metrics, and logs. Provides vendor-neutral instrumentation APIs that export telemetry data to Jaeger, Zipkin, Prometheus, Grafana, Datadog, and any OTLP-compatible backend. Used to instrument Go microservices for distributed tracing and metrics without vendor lock-in.
Score Breakdown
⚙ Agent Friendliness
🔒 Security
OTLP exporters support TLS and auth headers. Telemetry data may contain sensitive info — configure span attribute filtering. CNCF project with active security review.
⚡ Reliability
Best When
You're instrumenting Go microservices for distributed tracing and want vendor-neutral observability that works with any OTEL-compatible backend.
Avoid When
You have a single-service app where simpler logging suffices, or you're locked into a vendor-specific SDK that provides equivalent functionality.
Use Cases
- • Instrument Go agent services with distributed tracing to track request flows across microservices using spans and context propagation
- • Collect Go service metrics (request rates, latencies, error rates) and export to Prometheus or Grafana with OTLP exporter
- • Add automatic instrumentation to HTTP (net/http, gin, echo) and gRPC handlers in Go services with otelhttp/otelgrpc middleware
- • Propagate trace context across Go agent pipeline steps for end-to-end visibility of agent workflow execution
- • Export telemetry to multiple backends simultaneously using OpenTelemetry Collector for flexible observability routing
Not For
- • Simple single-service applications without distributed tracing needs — basic log-based observability may be sufficient
- • Teams starting with observability — OpenTelemetry's API/SDK/exporter separation has a learning curve; start with simpler tools
- • Non-Go services — use language-specific OpenTelemetry SDKs (otel-python, otel-js, otel-java)
Interface
Authentication
SDK library. Backend auth (API keys, mTLS) is configured on exporters (OTLP exporter headers).
Pricing
Apache 2.0 license. CNCF project.
Agent Metadata
Known Gotchas
- ⚠ OpenTelemetry Go has two module paths (go.opentelemetry.io/otel for APIs, go.opentelemetry.io/otel/sdk for SDK) — must import both; API-only imports produce no-op instrumentation
- ⚠ Global tracer provider must be set with otel.SetTracerProvider() at startup — forgetting this means all spans are no-ops
- ⚠ Context propagation is manual in Go — must pass context.Context through all function calls; breaking the context chain loses parent span association
- ⚠ Contrib packages (otelhttp, otelgrpc, otelgorm) are in a separate repo (opentelemetry-go-contrib) — install separately for auto-instrumentation
- ⚠ Sampler configuration affects trace completeness — ParentBased sampler default may drop traces from non-instrumented callers; configure TraceIDRatioBased for sampling
- ⚠ OTLP exporter requires a collector endpoint — local testing needs OpenTelemetry Collector or Jaeger all-in-one running; not zero-config
Alternatives
Full Evaluation Report
Detailed scoring breakdown, competitive positioning, security analysis, and improvement recommendations for OpenTelemetry Go SDK.
Scores are editorial opinions as of 2026-03-06.