On this page

For AI agents: a documentation index is available at /docs/llms.txt. Append .md to any page URL for markdown, or send Accept: text/markdown.

Build charts in Amplitude: Add user segments

Amplitude Academy

Getting Started with Amplitude Analytics

Learn the most fundamental features of Amplitude Analytics, including cohorts.

Get started

If you haven't done so already, read adding events to your Amplitude charts before continuing with this article.

Advanced Segments is rolling out to GA

Advanced Segments is now in general availability rollout. It coexists with Classic Segments — both builders work in the same chart.

Events are only half of the equation. You also need to specify the users whose behavior you want to analyze.

Amplitude has two segment builders: Classic Segments and Advanced Segments. Classic Segments filter by user properties and cohorts, the same way segments have always worked. Advanced Segments extend that with a single builder combining user, event, and session conditions under one set of AND/OR logic.

Because they're designed for different types of analyses, Amplitude's Personas charts don't have a Segmentation Module. For more information on how to build analyses with these charts, follow the links above.

Refer to advanced features available through the Segmentation Module for more options.

Classic Segments

Classic Segments are Amplitude's original segment builder, available in all chart types that support a Segmentation Module. Use them to filter by user properties, cohorts, and behavioral conditions.

Create a user segment

First, decide which category of users your segment draws from: any users, active users, or new users.

Active and New user segmentation

The Active Users and New Users options are available in Event Segmentation, Funnel, Retention, and Sessions charts. Other chart types only support Any Users.

If you select Any Users, your analysis includes all users who triggered the events you want to analyze. This is the broadest choice.

To narrow the focus, select Active Users. Amplitude defines an active user as one who triggered at least one active event during a specified time range. Users who trigger only inactive events don't qualify. When you choose this option, Amplitude looks at events that any active user triggered during the days, weeks, or months your analysis covers.

The New User option is more specific. Amplitude defines a new user as a user who logs an event in Amplitude for the first time. When you choose this option, Amplitude looks at events these users triggered during the interval (days, weeks, or months) in which the user was new.

For example, if a user was new on July 17, and you set your analysis interval to Daily, only the events that triggered on that same day, July 17, appear on the chart, regardless of whether that user also triggered events the next day.

You can use Accounts to select any custom groups you have instrumented in place of users.

After you decide how to measure your users, use Filter by and Performed clauses to define your user segments.

Filters

To learn how to use filters to refine your user segments into more precise analytical tools, refer to Modify a user segment.

Add more segments

Amplitude doesn't limit your analysis to a single segment. To add more segments, click + Add Segment. Here, there are two segments to compare: one that includes users in the United States, and one that includes users in Brazil.

Group by user property

The Segmentation Module also includes a Group Segment by function.

If you have only one event in your analysis, it doesn't matter if you use group by in the Events Module or Group Segment by in the Segmentation Module. But if your analysis includes more than one event, adding a Group Segment by condition in the Segmentation Module applies that condition to all the events in your analysis. If you don't want that, apply a group-by condition in the Events Module on an event-by-event basis.

Using Group Segment by in the Segmentation Module limits your analysis to one user segment. If you need more user segments, apply Group by conditions to each event in the Events Module.

Your chart displays the top five segments by the selected measurement. You can add or remove segments from the chart in the data table below it. In the example below, the analysis groups by device family. The graph shows the number of daily active users in the last 30 days, grouped by the device family they used.

Users can fall into multiple segments if they have multiple values for a property in this time period.

You can also add more than one group-by condition.

Save a user segment

After you create a user segment, you can save it for reuse in another analysis. Saved user segments are globally available to other team members.

To save a segment, click Save Segment in the segment builder and follow the prompts.

To load a previously saved segment, click + Add Segment or + Filter and search for the segment by name.

To make a segment your default segment (the one Amplitude automatically loads when you create a new chart), click Set as default next to the segment's name.

Advanced Segments

Advanced Segments give you a single segment builder with unified AND/OR logic across user, event, and session conditions. Use Advanced Segments when you need to filter across multiple scopes in one segment. Use Classic Segments when you only need user-property or cohort conditions and prefer to stay with the familiar workflow.

Advanced Segments are available in Event Segmentation, Funnels, Data Tables, Metrics Explorer, and Sessions.

Segment scope

Each condition in an Advanced Segment belongs to one of three scopes:

  • User scope: filters by user properties, cohorts, or event sequences. Matches users who meet the conditions you specify. Supports THEN to find users who performed one event followed by another.
  • Event scope: filters by event properties and supports cart (array) property filtering. Narrows the analysis to events matching the conditions — only those events count, not all events from qualifying users.
  • Session scope: filters by session properties such as session duration. Narrows the analysis to sessions matching the conditions — only those sessions count, not all activity from qualifying users. Supports WITHIN to constrain event conditions to a time or page-view window within a session.

You can combine conditions across scopes using AND logic. OR logic is available within the same scope, with some restrictions. OR'ing a user-scope condition (a user property or cohort) with conditions in any other scope isn't supported.

Event sequences

User scope — THEN: Use THEN in a user-scoped condition to find users who performed one event followed by another. For example, to match users who completed a Sign Up event and then made a Purchase, add both events to the user condition and connect them with THEN.

Session scope — WITHIN: Use WITHIN in a session-scoped condition to constrain event conditions to a time or page-view window within a session. For example, to match sessions where a user triggered Event 1 and then Event 2 within 1 page view, add both events to the session condition and set the WITHIN window.

The WITHIN window supports time-based units (seconds, minutes, hours) and page views.

Coexistence with Classic Segments

Advanced Segments and Classic Segments can coexist on the same chart. To reuse a saved Classic Segment inside an Advanced Segment, click + Add Segment or + Filter and search for the segment by name.

Two exceptions apply:

  • Classic Segments that include interval cohorts can't combine with Advanced Segments.
  • A Classic Segment loaded in comparison mode (two or more saved segments displayed side by side) can't be applied as a pill in an Advanced Segment.

Save a segment as a cohort

You can convert any Advanced Segment into a saved cohort. When you promote a segment, Amplitude saves the segment definition and creates a cohort that references it. Future cohort computations reflect edits you make to the segment definition. To refresh cohort membership immediately, trigger a manual sync separately.

Was this helpful?