Migrate From Segment
Amplitude handles both Analytics and CDP needs. This document covers how to:
- Migrate your source and destination configuration.
- Update your SDK implementation to send data to Amplitude.
- Validate the migration.
The following table maps Segment offerings to their Amplitude equivalents.
| Segment | Amplitude |
|---|---|
| Connections | Sources & Destinations |
| Profiles | Audiences |
| Protocols | Data Management |
Recommended best practice
Follow a strict release process and configure multiple environments. Validate changes within each environment before deploying.
Add a source
To add a new source:
- From Data, click Sources in the Connections section.
- Click Add Source.
- Browse or search for the source you want to add.
- Follow the on-screen prompts.
For detailed instructions, refer to the documentation for the source you want to add.
Update SDK implementation
Segment and Amplitude SDKs both capture first-party data by tracking user interactions, and they work similarly aside from syntax differences. The following table maps concepts between Segment and Amplitude.
| Segment | Amplitude | Notes |
|---|---|---|
| write_key | api_key | Unique key that validates the source of the data. |
| Workspace | Project | Projects organize your data. |
| User | User | The user performing the action. |
| Identify | Identify | Identify updates user properties. |
| Track | Event | An event in Amplitude tracks an action a user performs. |
| Screen | Event | Create an event to track screen views. |
| Page | Event | Create an event to track page views. |
| Group | Group | A group is a collection of users. In Amplitude, one user can belong to multiple groups. Each group can have properties that you can query or forward when any user in the group performs an action. |
| Plugins | Plugins | Plugins extend Amplitude by running custom code on every event. |
Documentation for Browser 2 SDK.
Identify
Segment
analytics.identify('12091906-01011992', {
name: 'Grace Hopper',
email: 'grace@usnavy.gov'
});
Amplitude
setUserId('12091906-01011992');
identify(
Identify()
.set('name', 'Grace Hopper')
.set('email', 'grace@usnavy.gov')
);
Track
Segment
analytics.track('Article Completed', {
title: 'How to Create a Tracking Plan',
course: 'Intro to Analytics',
});
Amplitude
track('Article Completed', {
title: 'How to Create a Tracking Plan',
course: 'Intro to Analytics',
});
Group
Segment
analytics.group('UNIVAC Working Group', {
principles: ['Eckert', 'Mauchly'],
site: 'Eckert–Mauchly Computer Corporation',
statedGoals: 'Develop the first commercial computer',
industry: 'Technology'
});
Amplitude
Assign user to a group:
amplitude.setGroup('Working Group', 'UNIVAC')
Update properties of a group:
groupIdentify(
'Working Group',
'UNIVAC' ,
new Identify()
.set('principles', ['Eckert', 'Mauchly']);
.set('site', 'Eckert–Mauchly Computer Corporation');
.set('statedGoals', 'Develop the first commercial computer');
.set('industry', 'Technology')
);
For all other SDKs, refer to the relevant SDK documentation.
Validate events
Data validation is a critical step in instrumentation. Validate your event data using Amplitude's debugging tools.
Add a destination
To add a new destination:
- From Data, click Destinations in the Connections section.
- Click Add Destination.
- Browse or search for the destination you want to add.
- Follow the on-screen prompts.
For detailed instructions, refer to the documentation for the destination you want to add.
Migration checklist
Validate the migration to minimize impact on downstream data consumers.
- [x] Added all sources to Amplitude
- [x] Migrated existing tracking code to Amplitude SDKs
- [x] Validated events are flowing in to Amplitude correctly
- [x] Added all destinations to Amplitude
- [x] Validated data is flowing into destinations correctly
- [x] Validated downstream consumers aren't affected (for example, BI, Mktg, ML, Ops)
Frequently asked questions
Was this helpful?