How do you migrate from OpenCensus to OpenTelemetry without losing dashboards?
The move from OpenCensus to OpenTelemetry is two migrations run together: an application migration that replaces OpenCensus libraries with the OpenTelemetry SDK, and a Collector migration that replaces the OpenCensus agent with the OpenTelemetry Collector. Run both in stages, with the old and new telemetry flowing in parallel until dashboards and alerts are confirmed to match. The OpenTelemetry specification now marks OpenCensus compatibility as deprecated. Existing OpenCensus shims may keep working for backwards compatibility, but new OpenCensus compatibility is not required, so treat the shims as a bridge with an end date rather than a long-term target.
Effort depends mostly on three counts: the number of services, the number of languages in use, and the number of exporters and agents still in the path. A small fleet on one language with one exporter is a different job from a mixed estate with several OpenCensus agents. Before planning, inventory each service's OpenCensus version, its exporter, and every metric and span name that dashboards or alerts depend on. Confirm the exact versions and bridge support for your languages with the OpenTelemetry documentation and your SDK vendors, since support differs by language.
The specification's order is the safe default. Deploy the Collector with the OpenCensus receiver first, so existing senders still reach your back end. Then switch each application to the OpenTelemetry SDK with an OTLP exporter and the OpenCensus bridge, which is where most breaking changes surface, including Prometheus exporter type and unit suffix changes. Compare old and new series side by side, fix the dashboards and alerts that drift, and only then remove the OpenCensus agent. The point to protect is that dashboards keep working throughout, so keep the bridge in place until each renamed series has a verified equivalent. See the OpenCensus compatibility specification for the migration plan this sequence follows.
Which OpenCensus capabilities map to OpenTelemetry and which need rework
This table compares each OpenCensus capability in use with its OpenTelemetry counterpart and the migration work it needs. Read each row against your own libraries and agents, and treat any row marked for confirmation as a check to run in your language SDK version before you commit to a plan. The main takeaway is that tracing and context propagation usually bridge cleanly, while exporters, metric names and units need deliberate work.
| Capability | OpenCensus source | OpenTelemetry equivalent and migration note |
|---|---|---|
| Distributed tracing API | OpenCensus trace API and spans in application code | OpenTelemetry tracing API. The specification provides OpenCensus bridges so spans can flow through the OpenTelemetry SDK during the transition. Confirm bridge behavior in your language SDK version. |
| Metrics API | OpenCensus stats, views and measures | OpenTelemetry metrics API with instruments. Metric names, instrument types and units can change, so plan this as part of the application migration step. |
| Prometheus exporter | OpenCensus Prometheus exporter | OpenTelemetry Prometheus exporter or Collector Prometheus pipeline. Exporter type and unit suffix changes sit in the application migration step, not in the agent step. |
| Backend-specific exporters | Vendor exporters wired into OpenCensus (for example Stackdriver, Zipkin or Jaeger) | Replace with OTLP first, then decide the back end separately. Each vendor exporter needs a decision about whether the back end accepts OTLP directly or through the Collector. |
| Context propagation | OpenCensus propagation formats such as B3 or Trace Context | Trace Context is the default OpenTelemetry format. Confirm which propagators your services need during mixed-version rollout, since older services may still send OpenCensus headers. |
| OpenCensus agent and receivers | OC agent accepting OpenCensus gRPC or HTTP from services | OpenCensus receiver in the Collector during transition, then OTLP receivers. The OC agent is removed once each workload sends OTLP. |
| Attribute and label names | Labels and span attributes named under OpenCensus conventions | Semantic convention names may differ. Dashboards and alerts that filter on old names need updating. Confirm each renamed attribute in your SDK version. |
| Sampling and resource detection | OpenCensus samplers and manual resource tags | OpenTelemetry samplers and resource detectors. Confirm sampler configuration and resource attribute names in your language SDK before relying on them. |
Which metric and attribute names change, and how to keep dashboards working
Metric names, units and attribute keys can differ between OpenCensus output and OpenTelemetry output, so the dashboards, alerts and recording rules you already run may stop matching data without any visible error. The OpenCensus compatibility specification groups most of these breaking changes into the first step, where you install the OpenTelemetry SDK with an equivalent OTLP exporter and the OpenCensus bridges, before any instrumentation is moved. That makes the first step the right place to find out what changes. Start by inventorying every dashboard panel, alert rule and recording rule that queries an OpenCensus-derived series, and record the metric name, label or attribute keys, unit and exporter each one depends on. Confirm the exact new names against the current specification and your SDK version rather than working from memory, since exporter-specific suffixes and unit conventions vary by backend.
Next, build a mapping table with one row per old name and columns for the new metric name, the new attribute key, the unit, the exporter that produces it and the owning dashboard or alert. Use the same table to decide which old names need a permanent alias in your backend, such as a recording rule that republishes the new series under the old name, and which ones are simply retired after the cutover. Keep the table in version control so reviewers can see when a mapping changed. Treat any mapping you cannot confirm against the specification as an open item rather than an assumption.
During the parallel run, keep the old OpenCensus series and the new OpenTelemetry series flowing into the same backend, and compare them for the services you have already moved. Check that each mapped pair reports the same values for the same workload, and that alerts fire on both sides when you inject a known fault in a test environment. Set a written exit criterion for each dashboard, so the old panel is removed only after its replacement has been checked against the mapping table. Ask your backend vendor how it handles series with unit suffixes and renamed labels, because that behavior determines how much of the mapping you can handle with recording rules alone.
Documented paths and tools for the OpenCensus move
The OpenCensus move has a documented sequence: install the OpenTelemetry SDK with OTLP exporters and OpenCensus bridges, point the OpenCensus agent's traffic at the Collector, then cut each workload over to OTLP. The cards below cover each tool in that sequence, what it is for and where it stops. Confirm the stability of every component in its README before you depend on it.
OpenCensus bridges in the SDK
The OpenTelemetry SDK includes bridges that let existing OpenCensus instrumentation report through the OpenTelemetry pipeline while you migrate code in stages. The OpenTelemetry specification marks OpenCensus compatibility as deprecated, so bridges are a transition tool, not a destination. Check which signals and languages your bridges cover, and plan to remove them once each service is moved. Many breaking changes, including Prometheus exporter type and unit suffix changes, arrive in this step, so test dashboards and alerts here first.
OpenCensus compatibility specOTLP exporter in the SDK
The OTLP exporter replaces the exporters you used with OpenCensus back ends. Moving exporters to OTLP first lets you change the destination later without touching application code again. It stops at the SDK boundary: it sends data to a receiver, usually the Collector, and does not store or display anything. Confirm that your language's OTLP exporter supports the signals you send and the transport and encoding your receiver expects.
Collector OpenCensus receiver
The OpenCensus receiver in the Collector accepts traffic from workloads still sending OpenCensus data, so you can remove the OpenCensus agent while applications are migrated one by one. It is a transition component, not a long-term ingestion path. Verify the receiver's stability level in its README, confirm the ports and protocols your existing senders use, and set a date to retire it once no sender remains.
OTLP receiver and exporter after cutover
After each workload moves, the OTLP receiver accepts its data and the OTLP exporter forwards it to your chosen back end. This pair is the steady-state path that every migrated service uses. Its limit is that the Collector only passes data along: retention, query and alerting still depend on the back end you run. Check that every service is sending OTLP before you remove the OpenCensus receiver.
Collector Builder for a minimal build
The Collector Builder compiles a Collector with only the receivers, processors and exporters you name, so the OpenCensus receiver stays available only while you need it. Releases of the contrib distribution are signed and include SHA256 checksums and SBOM files, which helps when you verify what you deploy. Plan the component list before the build, and rebuild when you retire the OpenCensus receiver.
Collector configuration and security guidance
The Collector security best practices cover storing configuration securely, using encryption and authentication on receivers and exporters, and using the redaction processor to remove sensitive attributes. Recent Collector versions bind server components to localhost by default, so check that your receivers are reachable only where intended. Authenticator extensions can secure incoming OpenCensus and OTLP traffic and add credentials to outgoing exporter requests. Review these settings during cutover, because the old agent may have run with looser defaults.
Collector best practicesWhat order should an OpenCensus migration follow?
The sequence moves exporters to OTLP first, then instrumentation and the agent, so each step can be checked against data you already trust before the next one starts. Each step ends with an acceptance check that tells you whether to proceed.
Inventory libraries, agents, exporters and dashboards
Your platform or observability team lists every service that imports OpenCensus libraries, every OpenCensus agent or daemon in use, every exporter and back end receiving the data, and every dashboard and alert that depends on those metric or span names. Record the language and runtime of each service, since bridge availability and support vary by language. This step is complete when you have one inventory that maps each service to its exporter, its back end and the dashboards and alerts that read its data. Confirm bridge and language support with the OpenTelemetry documentation before you commit to a sequence.
Pilot the SDK with OTLP and OpenCensus bridges
In one low-risk service, install the OpenTelemetry SDK, configure an OTLP exporter equivalent to the current one, and add the OpenCensus bridges so existing OpenCensus instrumentation keeps emitting through the new SDK. The spec places most breaking changes here, including Prometheus exporter type and unit suffix changes, so review those names against your dashboards now. This step is complete when the pilot service emits the same signals it did before and the bridged data appears in the back end with the names your team expects.
Migrate exporters to OTLP first
Move every service's exporter to OTLP while the instrumentation stays on OpenCensus, so the data path changes before the code does. Send the OTLP traffic to the Collector or to a back end that accepts OTLP, depending on your design. Acceptance check: for each service, compare signal volume, metric names and attribute sets between the old and new exporter over the same window. Do not move to the next step for a service until those match or the differences are documented and approved.
Deploy the Collector with the OpenCensus receiver
Deploy the OpenTelemetry Collector with the OpenCensus receiver in front of your existing back ends, so services still sending OpenCensus data reach those back ends through one pipeline. Keep the Collector's configuration in version control and restrict its endpoints, since server components bind to localhost by default from v0.110.0 and any wider exposure is a deliberate choice you must make and secure. Acceptance check: the Collector receives test traffic from an OpenCensus sender and forwards it to every back end, with no dropped data in its own telemetry.
Run old and new pipelines in parallel
Keep the OpenCensus agent and the new Collector path running side by side for a period you agree with the owners of the dashboards and alerts. Send identical traffic through both where your setup allows, then compare the results per service: counts, latency distributions, error signals and attribute values. Acceptance check: the two paths agree within the tolerance your SRE and data owners sign off, and every difference has a recorded cause and fix. Confirm the agreed comparison window in writing before you start.
Migrate each workload to OpenTelemetry
Replace OpenCensus instrumentation in each service with the OpenTelemetry SDK and OTLP exporter, one service at a time, starting with the pilot. Each team tests the service in a non-production environment, checks that its signals match the parallel run, and then deploys. Acceptance check: the service emits native OpenTelemetry signals through the OTLP exporter, no OpenCensus calls remain in its code, and its owners have confirmed the telemetry in the back end.
Cut over dashboards and alerts
Update dashboards, recording rules and alert definitions to the metric and attribute names that the migrated services now produce, using the mapping from your inventory. Run each alert against known conditions where possible so you can confirm it still fires and still stays quiet when it should. Acceptance check: every dashboard and alert the inventory listed reads from the new names, and each owner has signed off on the cutover. Remove the old definitions only after this sign-off.
Remove the OpenCensus agent and decommission bridges
Once no workload sends OpenCensus data, shut down the OpenCensus agent and remove the OpenCensus bridges from SDK configuration and dependency lists. Keep the Collector as the single telemetry path. Acceptance check: no OpenCensus packages or agent endpoints remain in your build manifests or network rules, and the Collector's own telemetry shows the expected flow to each back end. Record the decommission date and the owner for future audits.
How the Collector sits between OpenCensus senders and the backend during transition
The diagram starts with services still sending through OpenCensus libraries and the OpenCensus agent, and shows services already moved to the OpenTelemetry SDK sending OTLP. Both lanes converge on a Collector that accepts the OpenCensus receiver and the OTLP receiver, then exports to the existing backend. The trust boundary sits at the Collector endpoints, where authentication and encryption should be confirmed before traffic from both lanes is accepted. The agent removal point marks when the old agent can be retired, once each workload has moved to OTLP.
Legacy senders and migrated services both reach one Collector before the existing backend.
Migration path for application libraries versus the OpenCensus agent
The application track follows the path in the OpenTelemetry specification's OpenCensus compatibility guidance. Each service first installs the OpenTelemetry SDK with an equivalent OTLP exporter and the OpenCensus bridges, so that spans and metrics keep flowing while the instrumentation code is still OpenCensus. Most breaking changes, including Prometheus exporter type and unit suffix changes, land in this first step, which is why it should be tested on one service before it is rolled across a fleet. Once the bridged service emits the same data through OTLP, teams migrate instrumentation calls to the OpenTelemetry API one component at a time and then remove the bridge.
- Exporter first: Switch the exporter to OTLP before changing any instrumentation calls, so the back end sees one protocol change at a time.
- Bridge installation: Add the OpenCensus bridges alongside the OpenTelemetry SDK and confirm span names, attributes and metric names against a known baseline.
- Per-service instrumentation changes: Move each service's OpenCensus calls to the OpenTelemetry API, starting with the services that have the fewest custom metrics.
- Bridge removal: Remove each bridge once no OpenCensus calls remain in that service, and record the removal date for the team that owns dashboards.
- Name and unit review: Check metric names, units and attribute keys after each step, since dashboards and alerts depend on them.
Before retiring a bridge, confirm with each service owner which dashboards, alerts and sampling rules depend on the old names, and verify that the OTLP output matches the baseline.
The agent track replaces the OpenCensus agent with the OpenTelemetry Collector, which can receive OpenCensus data through its OpenCensus receiver. This lets the Collector sit between existing senders and the back end while application teams migrate on their own schedule. Once every sender points at the Collector and the OpenCensus agent is removed, each workload moves to OpenTelemetry with the OTLP exporter, and the OpenCensus receiver can be removed from the Collector configuration. Because the Collector is a shared component, its receiver settings and access controls need to be set deliberately before senders are repointed.
- Deploy the Collector with the OpenCensus receiver: Run the Collector in the same role the agent played, such as next to services or on each host, and enable only the receivers you need.
- Point senders at the Collector: Repoint one sender group at a time and confirm data arrives in the back end before moving the next group.
- Set receiver exposure deliberately: Since v0.110.0, server components bind to localhost by default rather than 0.0.0.0. If the Collector must accept remote senders, set the bind address on purpose and restrict it with network controls and authentication, such as an authenticator extension.
- Remove the OC agent: Stop the OpenCensus agent only after the Collector path is verified for each sender group.
- Migrate workloads to OTLP: Move each workload to OpenTelemetry with the OTLP exporter, then remove the OpenCensus receiver once no senders use it.
Confirm the Collector version you plan to run against the current release listed in the Collector's release notes, and review the security best practices before exposing any receiver.
What drives the cost and duration of an OpenCensus migration
This table lists the factors that most change the effort of retiring OpenCensus, with why each one matters and how to keep it under control. Cost splits into one-time migration work and recurring Collector operation, and a written scope sets the quote.
| Driver | Why it matters | How to reduce it |
|---|---|---|
| Number of services and languages | Each service and language runtime needs its own SDK swap, bridge check and redeploy, so effort grows with the count of workloads. | Inventory every service with its language and OpenCensus libraries first, then group services that share a runtime and pattern. |
| Custom exporters and back ends | Custom OpenCensus exporters must be rewritten or replaced with OTLP exporters, and each back end may need its own configuration and testing. | List each exporter and its destination, retire unused ones, and confirm which back ends accept OTLP directly. |
| Dashboards and alerts that use old names | Metric and attribute renames change series names, labels and units, so queries and alert rules can break silently. | Export the names used in dashboards and alert rules, map old to new, and test each alert against both names during the parallel run. |
| OpenCensus features with weaker equivalents | Some OpenCensus features have no direct OpenTelemetry match, so the team must redesign instrumentation or accept a behavior change. | Review the features in use against the compatibility specification early and record each gap as a decision with an owner. |
| Collector pipeline complexity | Replacing the OpenCensus agent means building receivers, processors and exporters, and processing rules add testing and tuning work. | Start with a minimal pipeline that receives OTLP and the OpenCensus receiver, add processors one at a time, and version the configuration. |
| Number of environments | Kubernetes clusters, virtual machines and air-gapped networks each need their own packaging, image sourcing and rollout steps. | Standardize the deployment method per environment and confirm how Collector artifacts reach isolated networks before the schedule is set. |
| Change control and parallel-run duration | Regulated change processes, approvals and the period when both pipelines run side by side set the calendar more than the code does. | Agree the change calendar and parallel-run exit criteria in the written scope, and reuse one approval pattern across services. |
| Team skill with the Collector | Teams new to Collector configuration, debugging and upgrades need more time to build and run pipelines safely. | Assign owners, run a configuration review with the team, and use the Collector's built-in debugging before handover. |
| Recurring Collector operation | After cutover, someone pays to run, patch, monitor and upgrade the Collector fleet, which is an ongoing cost rather than a one-time one. | Ask any quote to separate one-time migration work from recurring operation, and state who owns upgrades and on-call support. |
What usually goes wrong in OpenCensus to OpenTelemetry migrations
Most OpenCensus migration problems come from changes that look small in code but reach far into the rest of the stack: metric names, bridges, trace context, network exposure, and data content. Each card below names the failure, the prevention step, and the check the team can run before cutover.
Broken dashboards and alerts after renames
Metric names, units and attribute keys can change when OpenCensus instrumentation moves to OpenTelemetry, and the specification groups many of these breaking changes into the step where the SDK and bridges are first installed. Dashboards, recording rules and alerts keyed to old names then go silent without an error. Before cutover, export a list of every metric name and label used in existing dashboards and alert rules, then compare it against what the new pipeline emits in a staging environment.
OpenCensus compatibility specBridge or receiver feature gaps
An OpenCensus bridge or the Collector's OpenCensus receiver may not support every feature a service uses, such as a particular exporter, instrument type or metadata field. The gap shows up as missing data rather than as a failure. Inventory the OpenCensus features each service calls, then confirm each one against the current documentation for the bridge and receiver versions you plan to run, and record anything unsupported as an explicit migration item.
Trace context mismatches during mixed periods
While some services still emit OpenCensus spans and others emit OpenTelemetry spans, the propagation format and span relationships can disagree, which breaks traces at the boundary between them. Traces appear split, with orphaned child spans or duplicated roots. Run a test request across each boundary between an OpenCensus service and an OpenTelemetry service, then confirm in the back end that one trace ID spans both sides before moving the next service.
Collector endpoints exposed beyond their network
A Collector that replaces the OpenCensus agent opens receiver ports that accept telemetry from every service on the network. Since Collector v0.110.0, server components bind to localhost by default rather than 0.0.0.0, but configurations copied from older agent setups or edited to listen on all interfaces can still expose them. Check the effective receiver endpoints on each Collector, confirm they match the intended network, and add authentication on receivers where the security guidance recommends it.
Collector security practicesSensitive data leaking into telemetry
Moving instrumentation often changes which attributes are captured, and new SDK defaults or added attributes can carry user identifiers, query strings, headers or tokens into traces and logs that were previously filtered out. Sensitive values then reach back ends with weaker access controls. Review the attributes each migrated service emits in a sample trace, and add the redaction processor to the Collector to remove the attributes your data classification forbids.
Cutover without a parallel-run comparison
Switching all traffic to the new pipeline at once removes the baseline needed to tell whether data volume, latency labels or alert coverage changed. Problems then surface as production incidents instead of test findings. Run the OpenCensus and OpenTelemetry paths side by side for a defined period, compare span counts, metric totals and alert firing history for the same workloads, and only retire the old agent once the differences are explained and approved by the service owners.
Questions teams ask before an OpenCensus migration
How much effort does an OpenCensus to OpenTelemetry migration take?
Effort depends mainly on how many services, libraries and agents still run OpenCensus, and how many dashboards and alerts depend on its metric and attribute names. The specification groups most breaking changes into one early step, which means the work is front-loaded: installing the OpenTelemetry SDK with an equivalent OTLP exporter and OpenCensus bridges, then reviewing renamed metrics and units. Per-service effort is then mostly instrumentation review and testing. No duration figure is supplied for this work, so ask any provider for a written scope that lists services, languages, exporters, agents and dashboards, and an estimate tied to that list. Ongoing effort is small once the pipeline is stable, but it recurs when you upgrade SDKs or the Collector.
How long should the parallel run last, and what does it need?
A parallel run keeps OpenCensus data flowing while OpenTelemetry data is compared against it, so you can confirm that traces, metrics and attributes match what your dashboards and alerts expect. The specification sequences the work so the bridge step runs before instrumentation moves, which makes the overlap period the main risk window. No duration is supplied, so set the exit criteria first: every dashboard and alert mapped to a new name, every workload confirmed on OTLP, and no unexplained gaps. The run needs both pipelines available, a way to compare results side by side, and owners who can sign off on each change.
What must our team provide before the migration starts?
Most delays come from missing inputs rather than from code changes. Your team should provide:
- An inventory of every service, library version, OpenCensus agent and exporter in use.
- Read and deploy access to the repositories, build pipelines, runtime environments and Collector hosts involved.
- Change windows agreed with service owners, including rollback windows.
- A named owner for each dashboard, alert and runbook that reads OpenCensus metric or attribute names.
Ask for the owner list early, because dashboard changes often need people outside the platform team.
Can our in-house team complete the migration without outside help?
An in-house team can complete the migration if it has engineers who know each language's instrumentation, someone who can operate the Collector, and time to test each step against live dashboards. The main risks are the early bridge step, which touches many components at once, and the Collector configuration, which needs careful security settings. Check your team against the specification's steps and against the Collector's security guidance. An outside partner is useful when the inventory is large, when the parallel run must be strictly controlled, or when staff are stretched. Any engagement should begin with a written scope that names deliverables and acceptance criteria.
Can we replace the OpenCensus agent without changing application code?
Partly. The specification describes deploying the Collector with the OpenCensus receiver, removing the OpenCensus agent, and then migrating each workload to OpenTelemetry with the OTLP exporter. The receiver lets the Collector accept data from workloads that still send OpenCensus, so the agent can be retired before application code changes. However, the application libraries still need to move, because the agent is only the collection hop. Confirm with the specification and the Collector component documentation that the OpenCensus receiver is available in your Collector distribution and at the version you plan to run, since component stability varies.
Is OTLP required everywhere, or can some exporters stay as they are?
The specification's migration plan moves exporters to OTLP as part of installing the OpenTelemetry SDK, so OTLP is the target protocol for the migrated workloads. Where a back end cannot yet receive OTLP directly, the Collector can translate data between formats, which lets you keep that back end while the workloads move. Confirm each back end's supported ingest path with its vendor or project, and list any exporter that must stay on a non-OTLP path until its owner signs off. Those exceptions belong in the scope document, with a date for review.
How DeployOpen scopes and delivers an OpenCensus to OpenTelemetry migration
DeployOpen treats an OpenCensus to OpenTelemetry move as a written, fixed-scope engagement that starts with an inventory of libraries, agents and exporters. The work is planned around your own infrastructure, from the first exporter change through to retiring the OpenCensus agent and handing the pipeline over to your team.
How we scope
- Inventory every OpenCensus library, exporter, agent and service that emits telemetry today.
- Record which signals, backends and dashboards depend on current metric and attribute names.
- Agree in writing which services migrate, which wait, and which behavior changes are accepted.
How we build
- Install OpenTelemetry SDKs with OTLP exporters and OpenCensus bridges in a controlled first step.
- Deploy the Collector with the OpenCensus receiver so existing senders keep working during the move.
- Migrate workloads one at a time, checking exported names, units and Prometheus output against the inventory.
How we hand over
- Document the Collector configuration, component versions and every renamed metric or attribute.
- Deliver a list of retired OpenCensus components and the order in which they were removed.
- Walk your platform and operations teams through the pipeline and the evidence gathered for each service.
How we support
- Engagements are fixed-scope, with scope, deliverables and timelines agreed in writing before work starts.
- Ongoing support, Collector upgrades and continuous testing are available as a retainer.
- Confirm with DeployOpen which release channel, upgrade cadence and support hours your retainer includes.

