Comparison
Langfuse vs LangSmith for Tracing AI Agents
Both trace agents, evaluate them and version their prompts. They differ in who can run them, how they take OpenTelemetry spans, and what a long agent run costs to keep.
By The Instrumented Agent Editors · Checked against Langfuse and LangSmith documentation on
The short answer
Langfuse is an open-source (MIT) LLM engineering platform you can use as a managed cloud or run yourself at no licence cost; it has been part of ClickHouse since January 2026. LangSmith is LangChain's commercial platform for tracing, evaluating and deploying agents, offered as a cloud service, with bring-your-own-cloud and self-hosted options on its Enterprise plan.
If your agents are built on LangChain or LangGraph and you are happy on a hosted service, LangSmith is the shorter path: tracing is an environment variable away. If you need traces to stay in your own infrastructure without an enterprise contract, or your agents span several frameworks and languages that already emit OpenTelemetry, Langfuse is the easier fit.
Langfuse and LangSmith at a glance
| Langfuse | LangSmith | |
|---|---|---|
| Made by | Langfuse, acquired by ClickHouse, Inc. in January 2026 | LangChain, the company behind LangChain and LangGraph |
| Source code | Core platform open source under MIT; some enterprise features (audit logs, SCIM, retention policies) need a licence key when self-hosted | Proprietary platform; the client SDKs are open source |
| Where it runs | Langfuse Cloud (EU, US, Japan and a HIPAA region), or self-hosted with Docker Compose, Kubernetes (Helm) or Terraform | LangSmith Cloud (US, EU and APAC regions), BYOC, or self-hosted on Kubernetes as an Enterprise add-on |
| What cloud usage is metered on | Billable units: every trace, every observation in it (spans, generations, events) and every score | Seats on paid plans, plus traces, billed by retention tier (base or extended) |
| OpenTelemetry ingest | OTLP over HTTP (JSON or protobuf) at /api/public/otel; no gRPC. The Python and JS/TS SDKs are built on OpenTelemetry | OTLP at your API URL plus /otel; maps GenAI semantic conventions plus OpenInference, Traceloop and Logfire attributes |
| LangChain and LangGraph | Supported through Langfuse's LangChain callback handler | Native: set LANGSMITH_TRACING=true and an API key |
| Trace retention (cloud) | Data access window set by plan; self-hosted keeps what you store | Base traces 14 days, extended 180 days by default; some actions upgrade a trace to extended |
| Evaluation and prompts | Datasets, experiments, LLM-as-judge evaluators, annotation queues, prompt versioning with labels, playground | Datasets, offline and online evaluators, annotation queues, prompt playground |
| Limit worth knowing | With raw OpenTelemetry, user, session, tags and metadata must be set on every span to filter by them | A trace holds at most 25,000 runs; runs past that are rejected |
How each one models an agent run
Both tools store an agent run as a tree. In Langfuse the root is a trace and every step under it is an observation: a span for a unit of work, a generation for a model call, an event for a point in time. Traces that belong to one conversation are grouped into a session, and scores (from evaluators, annotators or users) attach to a trace or an observation.
In LangSmith every step is a run, and a trace is the tree of runs under one root run. Traces live in a tracing project (in an agent-based workspace, one project per agent environment), and the traces of one conversation form a thread. Feedback attaches to runs.
For a multi-step agent the two shapes carry the same information: the plan, each model call, each tool call and each handoff as a child of the run that caused it. What matters more is that your spans are designed so a failure can be located in that tree; see span design for multi-step agentic pipelines.
Getting spans in with OpenTelemetry
Both accept OTLP, so an agent already instrumented with OpenTelemetry can send to either without code changes, only exporter settings. The details differ:
- Langfuse: set
OTEL_EXPORTER_OTLP_ENDPOINTto your region's/api/public/otelURL (or your own host's) and authenticate with HTTP Basic auth built from your public and secret keys. Add thex-langfuse-ingestion-version=4header; Langfuse's docs say spans sent without it can take up to 10 minutes to appear. Only HTTP is accepted, so a gRPC exporter has to be switched to HTTP. - LangSmith: set
OTEL_EXPORTER_OTLP_ENDPOINTto your API URL plus/oteland pass the API key in anx-api-keyheader. Use the base URL: an exporter appends/v1/tracesitself, and adding it twice returns a 404. For LangChain and LangGraph apps,LANGSMITH_OTEL_ENABLED=trueturns on the built-in OpenTelemetry integration. - Both map the OpenTelemetry GenAI attributes onto their own model, and both also ship Python and TypeScript SDKs that add framework integrations on top of plain OTLP.
Because both are OTLP backends, you can trial them side by side: LangSmith's docs describe fanning one span stream out to several backends through an OpenTelemetry Collector, which works the same way for Langfuse. The attributes to standardise on first are in OpenTelemetry GenAI semantic conventions for agent spans.
What a long agent run costs to keep
The two clouds count different things, and agents make the difference visible. Take one agent run whose trace holds 40 observations (spans for model calls, tool calls and handoffs) and is scored once by an evaluator:
- Langfuse counts it as 42 billable units: the trace, the 40 observations and the score, since every trace, observation and score is a unit.
- LangSmith counts it as one trace at its retention tier. Attaching feedback through the API with retention extension, an online evaluator with retention enabled, or a matching automation rule can upgrade that trace to extended retention, which is billed separately.
So span-heavy agents weigh more on Langfuse's meter, while long retention and many seats weigh more on LangSmith's. Neither price is listed here because both change; put your own span count per run and runs per month into Langfuse's pricing calculator and LangSmith's pricing page. If volume is the problem on either, sampling strategies for high-volume agent trace pipelines covers what to keep.
Self-hosting and where trace data lives
Self-hosting is the sharpest difference. Langfuse's open-source edition runs every core feature with no usage limit: two application containers (web and worker) on PostgreSQL, ClickHouse, Redis or Valkey, and S3-compatible blob storage. It is the same architecture as Langfuse Cloud. You run and scale those stores yourself; a licence key adds enterprise features such as audit logs, data retention policies and SCIM.
Self-hosted LangSmith runs in your own Kubernetes cluster and is an add-on to the Enterprise plan, so it starts with a sales conversation. LangSmith also offers BYOC, where the data plane runs in your cloud account. On either product's cloud, pick the region at sign-up: both offer US and EU, Langfuse adds Japan and a HIPAA region, LangSmith adds APAC.
If traces have to be kept as evidence, read audit logging for AI agents in regulated industries before choosing: retention defaults and who can delete a trace matter as much as where it is stored.
Evaluating what the traces show
Both go past tracing into evaluation: datasets built from production traces, experiments that rerun them, LLM-as-judge evaluators alongside scores from your own code, and annotation queues for human review. Both can score live traffic as it arrives. The feature lists are close; the practical question is which one your evaluators already target, and whether you want evaluation data under the same licence and hosting as your traces.
Neither tool decides what a wrong answer looks like for your agent. That depends on what you record on each span; see span-level correctness signals that surface wrong answers in clean traces and establishing a behavioral baseline for a deployed agent.
Which one to pick
Choose Langfuse if
- Traces must stay in your own infrastructure and you don't want an enterprise contract to get there
- You want to read, patch or audit the code of the system holding your traces
- Your agents span several frameworks or languages, and you already export OpenTelemetry
- Your agents are LangChain-based, but you want an open-source backend all the same
Choose LangSmith if
- Your agents are built on LangChain or LangGraph and you want tracing with no extra instrumentation
- You expect to deploy those agents on LangChain's own platform as well
- Your runs have many spans each, and per-trace metering suits your volume better
- You'd rather not operate ClickHouse, PostgreSQL, Redis and blob storage yourself
Sources and where to check prices
- Langfuse: OpenTelemetry for LLM observability
- Langfuse: Pricing (Cloud) and billable units
- Langfuse: Self-hosted pricing
- Langfuse: Self-host Langfuse
- Langfuse: Langfuse joins ClickHouse
- LangSmith: Trace with OpenTelemetry
- LangSmith: Usage and billing
- LangSmith: Self-hosted LangSmith
- LangSmith: Plans and pricing


