Migrate from Segment to RudderStack

Moving from Segment to self-hosted RudderStack keeps existing SDK calls working, but identity, destinations and validation take the real effort. This page plans that move.

On this page

Migrate from Segment to RudderStack: what the move involves

If your renewal, a residency requirement or lock-in concern has pushed you toward self-hosting, the good news is that RudderStack's server is fully compatible with the Segment API, so existing Segment SDK integrations can keep working. The move is therefore mostly about identity, destinations and validation rather than rewriting every tracking call. The work usually falls to analytics engineers who own the tracking plan, platform engineers who run the Kubernetes or PostgreSQL footprint, and data owners who sign off on which warehouses and tools receive each event.

Before planning any of this, your legal and procurement teams should read the license. The rudder-server README states that the server is released under the Elastic License 2.0, which is source-available rather than OSI-approved open source. RudderStack's own licensing post described the same core as AGPL-3.0 in February 2021, so older articles may give a different answer. Confirm with RudderStack, in writing, which terms apply to the self-hosted build you intend to run and whether any commercial use you have planned falls within them.

RudderStack's Segment migration guide follows three phases. The first covers the basic SDK and event and property migration, where you point existing analytics calls at the RudderStack data plane and confirm that track, identify and page events arrive with the expected names and properties. The second covers advanced techniques: custom transformations, carrying over anonymous IDs and user traits, and moving high-traffic sites gradually. Identity is the step most often underestimated, because the anonymous IDs and traits you migrate determine whether returning users stay one person in downstream tools. The third phase is testing and validation, which you should not skip. Keep Segment running in parallel until event counts, identity stitching and each destination match on the same sample of traffic, then turn Segment off. Check your current Segment plan's export settings first, since they determine what history you can take with you.

Which Segment capabilities move cleanly to RudderStack

This table maps the main Segment capabilities to their RudderStack equivalents and marks each as clean, needs rework, or gap. Read the status column first, then confirm the rework and gap rows against your own sources, destinations and tracking plan before you set a cutover date.

Segment capabilityRudderStack equivalentStatusWhat to confirm
Analytics.js and mobile SDK calls (track, identify, page)RudderStack SDKs with Segment-compatible API callsCleanConfirm the SDK version and that your event names and properties arrive unchanged in test
Group calls and group traitsGroup calls accepted through the Segment-compatible APINeeds reworkCheck how group traits map to your warehouse tables and downstream tools
Sources and write keysSources configured in the control plane UINeeds reworkRecreate each source and confirm which keys your SDKs and server code use
Destinations and connection mappingDestinations connected per source through the control planeNeeds reworkMap each destination's field settings and confirm it is supported in the open-source edition
Tracking plans and schema enforcementNo direct equivalent confirmed for the open-source editionGapExport your Segment tracking plan and decide whether validation moves to tests or transformations
Custom transformationsTransformations run through rudder-transformerNeeds reworkPort each function and retest against sample payloads
Warehouse syncWarehouse destinations for supported warehousesNeeds reworkConfirm warehouse connector coverage and backfill approach for history
Segment Unify, Engage and ProtocolsNot promised as equivalentsGapConfirm each feature separately with RudderStack and your own team before depending on it
Control plane UI and Cloud featuresOpen-source control plane differs from Cloud editionsNeeds reworkCompare the feature list of the edition you will run against your current workspace settings

What carries over and what must be rebuilt

SDK-level instrumentation can usually stay in place. RudderStack's server README states that it is fully compatible with the Segment API, so existing Segment SDK calls for track, identify and page can keep working once the SDK is pointed at RudderStack. The anonymous ID that the SDK generates in the browser or app is the thread that ties pre-login and post-login activity together, and the migration guide's first phase is built around keeping those calls intact. Confirm this in your own environment before you assume it: check each SDK version and each source you run, because older or custom instrumentation is where compatibility surprises tend to appear. Treat the guide's basic SDK phase as a test of your event stream, not as a formality.

Several things need explicit work. User traits stored on Segment profiles, historical events, destination configurations and any Segment-only features such as Protocols or Engage audiences do not move by changing the SDK. The guide's advanced phase covers custom transformations, migrating user data and traits, and moving high-traffic sites gradually. Plan that phase as a separate workstream with named owners for transformations, identity data and each destination. Ask RudderStack, before you rely on it, what historical data export is possible from a Segment workspace, in what format, for which sources, and whether anonymous IDs and traits can be imported with their original timestamps. Do not count on historical continuity for reporting until that answer is in writing.

Destinations need the most manual rebuilding. Each Segment destination must be recreated in RudderStack with its own credentials, field mappings and event filters, and each mapping should be checked against the tracking plan you export from Segment. Validation is the last phase of the guide, and it is where you decide whether Segment can be switched off. Compare event counts, property names and trait values per destination over a period you choose, and keep Segment running until the gaps are explained. The Jitsu migration path described elsewhere on this site uses a different sequence, so do not mix the two plans.

Data, identities and destinations to move

A Segment to RudderStack move carries more than SDK calls. Identities, schemas, destination settings, warehouse links and custom code each need a documented path and a record taken from Segment before anything is switched off. Work through these items in order so the validation phase has a known baseline to compare against.

SDK source configuration

Each Segment source has a write key and a set of enabled SDK settings that decide how browser and server calls are sent. RudderStack's documented path keeps the same Segment SDK calls and points them at a RudderStack data plane, so the write key and endpoint must be recorded per source. Note which sources are browser, server or mobile, which environments use which keys, and any source-level settings such as domain allow lists. Confirm with RudderStack how each source maps before changing any production key.

Segment migration guide

Anonymous IDs and user traits

Anonymous IDs tie pre-login activity to a person once they identify, so a break here splits one user into two profiles. The migration guide's advanced phase covers carrying user data and traits across. Export a sample of anonymous IDs and the traits stored for identified users, then confirm with RudderStack how existing IDs are preserved and how trait updates are replayed. Test one returning user end to end before rolling out to all traffic.

Migration guide phases

Tracking plan and event schemas

Your tracking plan defines event names, required properties and types, and it is the reference for checking that migrated events still match. Export the plan, the list of event names in use and the property types for the top events by volume. Decide whether RudderStack's own data governance will enforce the same schema or whether validation will run in your test environment. Schema drift between the two systems is the most common cause of silent reporting gaps.

Destination mappings and credentials

Each Segment destination has its own settings, event mappings and stored credentials, and none of them transfer automatically. Record every connected destination, the events and fields it receives, any field mapping or consent filter, and which credentials it uses. Rotate or re-enter API keys in RudderStack rather than copying secrets between tools, and keep a list of which team owns each credential. Confirm each destination's RudderStack connector and its supported event types before turning Segment off.

Warehouse connections

Warehouse destinations depend on schemas, sync schedules and the service accounts that write to them. Record the warehouse type, target schema or dataset names, table naming, sync frequency and the account and role used by Segment. Plan how RudderStack will write to the same tables so downstream dashboards and models keep working. Ask RudderStack to confirm the exact table layout and whether historical rows will remain under the Segment load until the cutover is complete.

Transformation code

Custom transformations in Segment, such as event enrichment, property renaming or filtering, must be rewritten for RudderStack's transformation layer. The migration guide lists custom transformations as an advanced technique, so inventory every function, its inputs and its outputs. Store the source code in version control and write test payloads for each one. Confirm which runtime and language features RudderStack supports before porting, since behavior can differ on edge cases such as null values.

Transformations in the guide

The migration sequence from inventory to decommission

This sequence moves Segment traffic to RudderStack in controlled stages, so each stage produces evidence that the next one depends on. Segment is switched off only after a parallel run has shown that events, identities and destinations match what your teams and downstream tools expect.

  1. Inventory sources, destinations and tracking calls

    Engineering and data owners list every Segment source, every connected destination, every tracking plan and every place where track, identify, page and group calls are made, including server-side and mobile code. The product of this step is a source inventory with an owner for each item, plus a list of the downstream tools and warehouse tables that consume each destination. You know it is done when the inventory has been reviewed by the teams that own those consumers and no source is unassigned.

  2. Pick a low-risk pilot source

    Choose one source with moderate traffic, a small set of event names and a clear owner, ideally a site or app that is not tied to a revenue-critical flow. Run its SDK calls through RudderStack alongside Segment, since RudderStack's README states that it is fully compatible with the Segment API, so existing Segment SDK integrations can keep working. The output is a pilot event comparison that shows matching event names, properties and counts between the two systems, and you know the pilot is ready to move on when the differences are explained and accepted by its owner.

  3. Migrate SDK calls, events and properties

    Phase one of RudderStack's Segment migration guide covers the basic SDK swap, then the event and property migration. Engineers point the SDK at the RudderStack data plane, keep track, identify and page calls unchanged where possible, and align event and property names with the tracking plan. The output is a migrated code change set and a short list of renamed or dropped properties, and it is complete when the pilot emits the same events the tracking plan defines.

  4. Carry over anonymous IDs and user traits

    Phase two covers advanced techniques, including custom transformations and migrating user data and traits. Plan how anonymous IDs will persist across the switch so that a visitor who starts on Segment and continues on RudderStack is not counted twice, and decide which user traits are copied, backfilled or left to re-identify. The output is a written identity and traits plan approved by the analytics and privacy owners, and the step is done when a test user's identity resolves the same way in both systems.

  5. Map destinations and validate events

    Phase three of the guide covers testing and validation. Each destination is configured in RudderStack, and the team checks that every event reaches it with the expected schema, consent flags and transformations. The output is a validated destination map listing each destination, its owner, the events it receives and the test evidence for each one, and the step is complete when every destination has been checked against the inventory from the first step.

  6. Run Segment and RudderStack in parallel

    Keep both systems receiving the same traffic for the period the owners agree on, then compare event volumes, identity counts and destination results each day. Discrepancies are logged with a root cause and a fix or an accepted exception. The output is a parallel run report, and it is complete when the discrepancies are closed and the owners of downstream reports confirm that their figures agree.

  7. Cut over and sign off the checklist

    Move the remaining sources to RudderStack in batches, starting with the lowest-risk ones, and update each SDK configuration and server-side call. A cutover checklist records the sources moved, the destinations confirmed, the rollback path and the approvers from data, engineering and privacy. The output is a signed-off cutover checklist, and the step is complete when no source still sends to Segment by design.

  8. Decommission Segment and archive exports

    Once the checklist is signed, disable Segment sources and destinations, export any data you must keep before the workspace is closed, and confirm which data Segment retains under your contract. Ask Twilio Segment to confirm the export and deletion options available on your plan before this step. The output is a decommission record with the export files, the deletion confirmation and the date Segment stopped receiving events, and the migration is closed when that record is filed with the data owner.

How traffic flows during the parallel run

Client SDKs and server sources keep sending events to Segment while the same calls are mirrored to a self-hosted RudderStack data plane, which holds its own state in PostgreSQL and routes to warehouse and tool destinations. Check each side against the other before any traffic moves. The comparison step is where mismatched event names, missing traits and wrong anonymous IDs show up, so it should pass for a sustained period before Segment is removed from the path.

Events flow to both Segment and self-hosted RudderStack until validation passes.

How to run Segment and RudderStack side by side

Run both pipelines in parallel before you change anything that matters. The idea is simple: keep Segment receiving the traffic your destinations depend on, send a copy of the same calls to RudderStack, and compare what arrives on each side. Because RudderStack's server is compatible with the Segment API, the usual approach is to point a duplicate path at the RudderStack data plane for each source, starting with a low-traffic property. Move high-traffic sites last, and roll them out in stages so that a problem affects a small share of users first. Record which SDK version and which write key or source each site uses before the first change, so you know exactly what was duplicated.

Compare three things on every stage: event counts per event name, identity behavior, and destination loads. Counts should match within the variance you expect from ad blockers and client-side timing, and any gap needs an explanation before you move on. Check that anonymousId and userId resolve to the same people on both sides, that identify traits land with the same values, and that page and track calls carry the same properties. For destinations, confirm that each one receives the expected volume from the RudderStack side and that no destination is getting events twice. Write these checks down as a go or no-go list for each stage, with an owner for each item.

Set the rollback path before the first duplicate call goes out. Decide who can revert a source's SDK or routing change, how long that takes in your release process, and what signal triggers it, such as a drop in event counts or a failing destination. Keep the Segment source active until the last stage passes. Before you start, confirm two points with Segment and RudderStack in writing: whether running both pipelines creates duplicate billing on the Segment side or the RudderStack side, and whether any destination deduplicates events by message ID. If a destination does not deduplicate, a parallel run can double-count conversions in ad platforms or analytics tools, so plan a clean test property for those destinations.

What drives the cost and duration of the move

This table lists the main drivers of effort and spend when moving from Segment to self-hosted RudderStack, with the one-time and recurring side of each. Read it as a checklist to scope a fixed-price quote: the more sources, destinations and stitching rules you have, the more the one-time work grows, while the infrastructure and upgrade load keeps recurring after cutover.

DriverWhy it changes cost or effortHow to keep it down
Number of sources and SDK versionsEach web, mobile and server source needs its SDK swapped and tested, and older SDK versions may behave differently under the new write key and endpoint.Inventory every source and SDK version before scoping, retire unused sources, and group sources that share a code path.
Mobile app release cyclesMobile SDK changes ship through app store review and users update on their own schedule, so Segment and RudderStack may both receive events for months.Plan a dual-write period, keep Segment forwarding until old app versions fall below an agreed share, and confirm the cutover date with product owners.
Tracking plan complexityEvery event name, property and type must be carried across, and gaps show up only when validation runs against real traffic.Export the current tracking plan, remove stale events, and agree a naming standard before the first SDK change.
Custom transformationsLogic that Segment applies through functions or destination settings must be rewritten as RudderStack transformations and tested separately.Limit transformations to what is required, document each one, and keep them under version control with test payloads.
Number of destinations and warehousesEach destination needs its mapping, credentials and test events rebuilt, and warehouse loads need reconciling against Segment's history.Prioritize destinations by business value, migrate the highest-volume ones first, and retire destinations nobody reads.
Identity stitching and user traitsAnonymous IDs, identify calls and traits must carry over so profiles do not split, and mistakes here are hard to see after cutover.Write the stitching rules down, test a sample of known users end to end, and agree how historical identities will be handled.
Data residency requirementsWhere the RudderStack data plane runs, and which destinations still receive data outside the region, can change the architecture and the list of approvals needed.Confirm residency requirements with legal before design, and list each destination's processing location in the scope.
Kubernetes and PostgreSQL operationsThe Helm-based production setup and PostgreSQL database need capacity planning, backups and monitoring that a managed Segment workspace does not require from your team.Ask the implementer for sizing guidance, a backup and restore test, and a runbook for database and pod failures.
Upgrades on a roughly weekly release cadencerudder-server ships releases roughly every week, so the team must decide which versions to adopt and test each one against its configuration.Pin a tested version, set a fixed upgrade window, and ask whether the scope includes ongoing upgrades or only the initial install.
One-time versus recurring costsOne-time work covers migration, validation and infrastructure setup; recurring costs cover hosting, upgrades, monitoring and on-call coverage after Segment is turned off.Ask any quote to split one-time work from monthly or annual running costs, and to state who carries on-call duties.

What usually goes wrong and how to prevent it

Most Segment to RudderStack migrations stall on a small set of predictable problems: identity that splits across old and new IDs, events that double or disappear during the parallel run, and destinations that receive data in the wrong shape. The cards below pair each risk with a check to run before the next step, so the cutover decision rests on evidence rather than on the SDK swap being done.

Identity fragmentation after ID changes

If the new SDK generates a different anonymous ID, or user traits are not carried over, one person appears as two or more profiles in downstream tools. Returning visitors then lose their history, and funnels break at the point of login. Before cutover, compare the anonymous ID and a sample of traits for the same test user in both pipelines, and confirm that identify calls send the same userId values. Document how the RudderStack guide handles user data and traits, and test a logged-in journey end to end.

Migration guide

Duplicate or missing events in parallel

Running Segment and RudderStack side by side is useful only if each event is counted once in each destination. Duplicated page or track calls inflate conversion numbers, while calls dropped by a changed SDK configuration leave gaps that look like real traffic drops. Set up a fixed test script that fires the same actions in both pipelines, then reconcile event counts by name and day in the warehouse before any destination is switched. Record the tolerance you accept, and keep it in the cutover sign-off.

Mobile SDK versions that lag

Native iOS and Android apps ship on store review cycles, and many users never update promptly. A mobile build that still sends to Segment can keep running after the web tier has moved, so turning Segment off too early silently drops events from older app versions. Inventory the SDK versions in production from your app analytics, then decide how long Segment must stay live for those builds. Ask RudderStack's documentation team which mobile SDK versions the migration path supports before you plan the timeline.

Destinations with wrong mappings

When destinations are recreated in RudderStack, field mappings, event name filters and consent settings are often re-entered by hand. A renamed property, a missing revenue field or a changed timestamp format can corrupt dashboards without raising an error. Export the Segment tracking plan and each destination's mapping settings first, then compare a sample payload at the destination endpoint for every event type you rely on. Transformations should be reviewed by a second person, since they run on every event.

Misreading the Elastic License 2.0

RudderStack's self-hosted server is released under the Elastic License 2.0, which is source-available rather than OSI open source. Teams that assume open-source terms may build a commercial service on it without checking the license limits on offering the software to third parties. Have legal counsel read the license text and the RudderStack licensing explanation against your intended use, including any customer-facing product. Treat this as a condition of the decision, not a footnote, and record the conclusion.

Licensing explained

Turning Segment off too early

Switching off Segment before validation is complete removes the only reference point you have. Gaps found after shutdown are hard to reconstruct, and rolling back means re-enabling a service whose configuration may have drifted. Define exit criteria in writing: event reconciliation passed, identity checks passed, mobile builds below an agreed threshold, and each destination verified. Keep Segment in read-only or forwarding mode for a defined period, and export the source and tracking plan settings before you disable anything.

How the migration differs by starting point

A small team with a handful of sources usually runs a single website or web app with the browser SDK, a few page and track calls, and one or two destinations. The work is mostly swapping the client-side snippet and confirming that the same events arrive with the same property names. RudderStack documents Segment API compatibility, so existing instrumentation can often stay in place while the write key and data plane endpoint change. Because the surface is small, one person can usually walk the full event list by hand.

  • Scope: one or two sources, the browser SDK, and the destinations you actually query.
  • Validation depth: a manual event checklist compared against a live event stream for a few days.
  • Anonymous IDs: confirm that returning visitors keep their identity after the swap, since the browser cookie is the main carrier.
  • Governance: a single owner who approves the cutover and records the change.
  • Rollback: keep Segment running until the checklist passes, then retire the source.

Before you start, confirm with the RudderStack documentation which SDK version and write key format your current setup needs, and list every destination that depends on the current events.

Questions teams ask before migrating from Segment to RudderStack

How much effort does a move from Segment to RudderStack take?

The effort depends mainly on how many sources, SDK call sites and destinations you run, and how much of your event schema is documented. RudderStack's migration guide is organized in three phases: swapping SDKs while keeping track, identify and page calls working, advanced work such as custom transformations and user traits, and then testing and validation. Each phase grows with the number of properties, tracking plan rules and downstream tools that depend on event names. Teams with a clean, documented tracking plan and few destinations usually have far less to change than teams with years of ad hoc events. Ask for a source and destination inventory before estimating anything.

How long does a Segment to RudderStack migration run?

Duration varies with traffic, the number of client applications, release cycles for mobile and web apps, and how many destinations must be rebuilt and verified. The phase that most often sets the pace is gradual rollout on high-traffic sites, because you need time to compare event counts on both systems before cutting over. Mobile apps also depend on store release schedules, so older app versions keep sending to Segment for a while. No duration is quoted here because none has been researched for this migration. Ask your implementation partner for a timeline built from your own inventory.

Can our own engineers run the migration without outside help?

A team with experience in event instrumentation, a Kubernetes or PostgreSQL platform owner, and someone who can own the destination configuration can often do it internally. The harder parts are usually operational: running the rudder-server and control plane, keeping versions current, setting up monitoring and backups, and proving event parity before Segment is switched off. If those skills are thin, or if compliance evidence is needed for the change, an outside implementation partner can take on defined parts of the work under a written scope. Decide which parts you own before you start.

Do existing Segment SDK calls keep working after the switch?

Yes, in principle: the rudder-server README states that RudderStack is fully compatible with the Segment API, so existing Segment SDK integrations can keep working. Compatibility at the API level does not mean every call has identical output. Check the write key, the data plane URL, and how your SDK version handles anonymous IDs, identify calls and page events. Test each client platform separately, because web, server, and mobile SDKs can behave differently under the same configuration. Keep a before and after comparison of sample payloads for every critical event.

Do historical events and user traits move to RudderStack?

Historical events stay in Segment or in the warehouse destinations you already populated, and RudderStack starts collecting from the point you cut over. Carrying over identity depends on your plan. The RudderStack migration guide covers migrating user data and traits in its advanced phase, so you need to plan how anonymous IDs are preserved and how existing user profiles are merged. Confirm with your vendor what Segment exports are available to you before you turn it off, and test that your warehouse still joins old and new records correctly.

What does the Elastic License 2.0 mean for self-hosting RudderStack?

The Elastic License 2.0 is a source-available license, not an OSI-approved open source license, so the rudder-server code can be read and self-hosted under its terms but is not open source in the OSI sense. RudderStack's pricing FAQ says the core data processing layer is the same in the Community and Enterprise editions, and the Enterprise edition adds reporting and clustering features. Have your legal team read the license text and check whether your intended use, including any hosting for other parties, is permitted. RudderStack's February 2021 licensing post described the same core as AGPL-3.0 at that time, so keep records of the version you deploy. If strict OSI open source is a hard requirement, consider Jitsu, which is MIT licensed.

What must our team provide before the migration starts?

You need an inventory of Segment sources, SDK versions, tracking plan rules, destinations and downstream consumers, plus access to the Segment workspace and the warehouse or storage targets. On the infrastructure side, plan for a Kubernetes cluster and a PostgreSQL database, with someone who can manage upgrades, since RudderStack recommends running the latest rudder-server and rudder-transformer versions. You also need named owners for app release coordination, data quality sign-off, and the decision to turn Segment off. Ask any partner to confirm these responsibilities in writing before work begins.

How DeployOpen works on this

DeployOpen plans, implements, integrates, documents and supports self-hosted open-source platforms inside your own infrastructure. For a Segment to RudderStack move, we scope the work in writing first, then build and validate the event flow in your environment before Segment is switched off.

How we scope

  • Engagements are fixed-scope, with scope, deliverables and timelines agreed in writing before work starts.
  • The written scope lists your sources, SDKs, pages and events, and the destinations that receive data.
  • We record which Segment features you use, such as tracking plans, custom transformations and warehouse destinations, so none are lost silently.

How we build

  • We deploy RudderStack in your own cloud account, data center or air-gapped network, with PostgreSQL as its dependency.
  • We swap SDK calls in phases, keeping track, identify and page calls working while anonymous IDs and user traits carry over.
  • We map each destination and configure access control, SSO and audit logging for the RudderStack control plane where your policies require them.

How we hand over

  • Validation covers event counts, property shapes and identity stitching between Segment and RudderStack before cutover.
  • You receive documentation of the deployed architecture, source and destination configuration, and the validation results.
  • We confirm the license terms of the self-hosted RudderStack server with you, so your legal and procurement teams can review them before go-live.

How we support

  • Ongoing support, upgrades and continuous testing are available as retainers after handover.
  • Upgrades follow the latest rudder-server and rudder-transformer releases, tested in a staging environment first.
  • Security testing of the deployed pipeline, including access and credential handling, can be scoped as a separate engagement.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.