Create and manage dynamic user segments in OneSignal to target personalized messaging based on activity, location, tags, and more.
A segment is a dynamic group of users defined by filters on Subscription attributes, behavior, and custom data. OneSignal segments update automatically as users interact with your app or site, with no extra tracking required. Use segments to target messages, exclude audiences, and trigger Journeys.
User-based segmentation is in beta. With it, segments contain users instead of Subscriptions. See User-based segmentation.
Push notifications, emails, and SMS messages are only sent to opted-in (subscribed) Subscriptions. The segment editor shows both subscribed and unsubscribed counts for transparency, but only subscribed Subscriptions receive messages when you target a segment. In-App Messages are displayed to all mobile Subscriptions, regardless of status.When used in Journeys, all Subscriptions in a segment, regardless of status, are evaluated to their respective Users and those users are entered into the Journey.
Event-based segments are built using filters on user-level activity rather than individual Subscriptions. A segment is event-based when it includes message event or Custom Event filters. You can add other filter types, such as tags and session filters, to the same segment. Examples include:
When a user last opened an email, SMS, or push notification sent via OneSignal.
Specific Custom Events tracked in your app or website.
An event-based segment includes all users who meet the criteria and automatically makes all of their Subscriptions eligible to be targeted, enabling richer audience definitions that can reach any of the user’s devices.
Segments can be created in the dashboard, via the API, or by uploading a CSV. Target your audience by including and excluding segments when sending messages or building Journeys.
Dashboard
Create and manage segments from Audience > Segments.
API
Create segments programmatically using the Create Segment API.
CSV Import
Bulk-import Subscriptions and Tags via CSV, then build segments that match them.
Filters define which Subscriptions belong to a segment. You can combine multiple filters using AND or OR logic. If no filters are selected, the segment defaults to every user of your app.
Filter
Description
First session
The first time OneSignal saw this user active on any device, including email or SMS. Equivalent to the user’s created_at timestamp.
Last session
The last time OneSignal saw this user active on any SDK-tracked device.
Session count
Number of times Subscription opened the app or visited the site. See Sessions.
Usage duration
Total seconds the Subscription had your app/site open.
Pulled from Android versionCode or iOS CFBundleShortVersionString. Combine with Device type to filter by different app versions per platform. See Target outdated app versions.
Device type
iOS, Android, Web Push (browser), Email, etc. Select multiple device types in one filter with “is any of”, or exclude them with “is not any of”.
User tag
Custom Tags you set via the SDK or API. See Add Tags.
Location
Filter by radius from coordinates (lat/long). Requires at least 1 meter and up to 2 decimal places of precision. See location permission.
Country
Based on last IP geolocation (ISO 3166-1 alpha-2 code).
Message event filters target users based on their interaction with one of your messaging channels within a certain window. See Message events for the full event catalog and conceptual reference.
Message event filters
First select the messaging channel you want to filter on, then specify the action to track and whether the user has or has not performed that action.You can specify a minimum, maximum, or exact number of times the user must have performed the action, as well as a time window ranging from the last 24 hours to the last 90 days. Use the between option to define a custom start and end range (in days ago).
The amount of time message event data is retained depends on your plan. The dashboard time window selector shows up to 90 days, but data beyond your plan’s retention period will not return results.
Retention by plan
Free, Growth, Pro, and Enterprise retention windows for message event data.
Custom Event filters let you target users based on meaningful actions they have taken in your app, website, or external systems.Custom event filters read stored events. Turn on storage for each event you segment on.
Custom event filters
Start by selecting:
The event name you want to filter on.
Whether the user has or has not performed that action.
The minimum, maximum, or exact number of times the action must be performed.
A time window during which the action must (or must not) occur. Choose a preset range or define a custom window using the between option (start and end in days ago).
After specifying the event, you can optionally filter on specific or multiple properties:
all: applies an AND condition across properties.
at least one: applies an OR condition.
Then set the properties you want to filter on using dot notation.
The segment editor shows how many subscribed and unsubscribed Subscriptions are in your segment, with a breakdown by channel (push, email, and SMS).
Subscribed Subscriptions are opted in and will receive messages when you target this segment.
Unsubscribed Subscriptions match your segment filters but are opted out and will not receive messages.
The channel breakdown lets you see reachable vs. unreachable Subscriptions per channel, which helps you understand which channels will be most effective before you build a message or Journey.
OneSignal always returns a count within approximately 15 seconds. Whenever possible within that time limit, you will see an exact count. For large or complex segments where exact counts can take a long time to compute, an estimate is shown instead.Estimates are labeled to make clear they are not exact:
Segment size
Format
Example
Above 10,000
Count with margin of error
140,000 +/- 5,000
Below 10,000
Less-than value
<4,800
Both formats are rounded to signal the number is approximate. Estimates will never display as 0: if your segment has very few members, the estimate reflects a small non-zero estimate to avoid implying the segment is empty when records may exist.
Segments with message event or custom event filters show counts on the Segments page once they finish processing. The segment editor doesn’t show a live estimate for them.
Your plan determines how many segments you can have at one time. Only active (non-paused) segments count toward this limit. Paused segments stay in your account but do not count, so you can pause segments you no longer use instead of deleting them.To free up capacity:
Pause segments you may want to use again later. The filter configuration is preserved and the segment can be resumed at any time.
Delete segments you no longer need.
See the pricing page for the segment limit on each plan.
Deleting a segment removes it from your list of segments. It does not delete the users inside it. To delete the users inside a segment, see Delete Users.
Dashboard
API
Go to Audience > Segments
Click the three-dot menu next to a segment
Select Delete
Segment options menu
Use the Delete Segment API. This only removes the segment definition, not the users inside it.
Not directly. Segments are dynamic groups defined by filters, so there is no option to hand-pick individual members. To group specific users:
Add a shared Tag to those users via the SDK, the API, or a CSV import.
Create a segment with a User tag filter matching that tag.
The CSV importer can also do both steps at once: enable Automatically create a Segment on the Review screen to tag every imported user and create a matching segment.To test with a small group, such as your own team’s devices, mark those devices as Test Users and create a segment with the Test Users filter.
Yes. The segment editor shows counts for both subscribed and unsubscribed Subscriptions. Subscribed Subscriptions are opted in and will receive messages. Unsubscribed Subscriptions match your filters but are opted out and will not receive messages.Only subscribed Subscriptions are targeted when you send a message.When used in Journeys and in-app messages, segments include both subscribed and unsubscribed Subscriptions.
OneSignal always returns a count within approximately 15 seconds. For smaller or simpler segments, this is an exact count. For larger or more complex segments, an estimate is shown instead.Estimates are clearly labeled with their precision. See Audience counts for details on how estimates are formatted and what they mean.
Can I combine custom event or message event segments with other segments?
Yes, with some send-time limits. A custom event segment can include other filter types such as message events, tags, and session filters.When sending messages outside of Journeys, you cannot include or exclude event-based segments (custom event or message event) with segments that have no event filters. In the dashboard, you can send custom event segments and message event segments together. The API accepts message event segments only with other message event segments, and custom event segments only with other custom event segments.Inside Journeys, you can combine event-based segments with any other segments.
No. Only active (non-paused) segments count toward your plan’s segment limit. Pause segments you no longer use to free up capacity without losing the filter configuration. See Segment limit for details.
Beta: segments of users that work across every channel.
Subscriptions
The push, email, and SMS records segments target.
Add user data tags
Tag users with custom data so segments can filter on it.
Custom Events
Send user actions to OneSignal for use in segments and Journeys.
Message events
Per-user record of message interactions, the basis of message event filters.
Journeys overview
Trigger automated workflows from segment membership.
Import users
Bulk-import users and Tags via CSV.
Was this page helpful?
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"OneSignal","description":"OneSignal is a platform for sending push notifications, emails, in-app messages, and SMS campaigns via a single API, Journey Builder, and a dashboard.","colors":{"primary":"#3A3DB3","light":"#E54B4D","dark":"#3A3DB3"},"logo":{"light":"https://mintcdn.com/onesignal/yJcueeDCO7UpHnnY/logo/OneSignal-Logo.svg?fit=max\u0026auto=format\u0026n=yJcueeDCO7UpHnnY\u0026q=85\u0026s=1fcfb6fef6d820fd9d99c74850711107","dark":"https://mintcdn.com/onesignal/s4WC_KzLxf8ornqq/logo/OneSignal-Logo-White.svg?fit=max\u0026auto=format\u0026n=s4WC_KzLxf8ornqq\u0026q=85\u0026s=2573a53b5aea961e18c82b3af8f31925"},"favicon":"https://mintcdn.com/onesignal/SGduBFHpiRdg5l6h/favicon.ico?fit=max\u0026auto=format\u0026n=SGduBFHpiRdg5l6h\u0026q=85\u0026s=c0a99fadc0553c658a83741c5611cef4","api":{"examples":{"languages":["curl","typescript","python","php","go","ruby","java","csharp","rust"],"autogenerate":true}},"navbar":{"links":[{"href":"mailto:support@onesignal.com","label":"Support"}],"primary":{"type":"button","label":"Dashboard","href":"https://dashboard.onesignal.com"}},"footer":{"socials":{"github":"https://github.com/OneSignal","linkedin":"https://linkedin.com/company/onesignal","youtube":"https://www.youtube.com/@onesignalofficial/playlists"}},"seo":{"metatags":{"apple-mobile-web-app-title":"OneSignal Docs"}},"fonts":{"family":"Nunito Sans"},"styling":{"eyebrows":"breadcrumbs","latex":true},"integrations":{"ga4":{"measurementId":"G-2DGWL0VYP5"},"posthog":{"apiKey":"phc_vZpvE0f5eyzcOt30FHer34yddVmNdo9kmlMVRBzLMtn","apiHost":"https://eu.i.posthog.com","sessionRecording":true}},"contextual":{"options":["copy","view","chatgpt","claude"],"display":"header"},"navigation":{"languages":[{"language":"en","href":"docs/en/home"},{"language":"cn","href":"docs/cn/home"},{"language":"ko","href":"docs/ko/home"},{"language":"ja","href":"docs/ja/home"},{"language":"tr","href":"docs/tr/home"},{"language":"pt-BR","href":"docs/pt-BR/home"},{"language":"es","href":"docs/es/home"},{"language":"fr","href":"docs/fr/home"}]}},"deployment":{"deploymentMetadataValue":{"subdomain":"onesignal","hasAudioNarration":false,"actualSubdomain":"onesignal","customDomains":["documentation.onesignal.com"],"gitSource":{"type":"github","owner":"onesignal","repo":"mintlify-docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6ae11e74212a940a5689cbb3","collectionId":"522138cb-edb7-4b84-a6f7-09c5b77a9ffa","schemaVersion":"v3","latestBuiltDeploymentHistoryId":"6ae11e74212a940a5689cbb3"},"feedback":{"thumbs":true},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6ae11e74212a940a5689cbb3","clientVersion":"0.0.3990","searchFilterCounts":[{"language":"en","tag":"User Guides","count":201},{"language":"es","tag":"Guías del Usuario","count":178},{"language":"fr","tag":"Guides utilisateur","count":178},{"language":"ja","tag":"ユーザーガイド","count":178},{"language":"ko","tag":"사용자 가이드","count":178},{"language":"pt-BR","tag":"Guia do Usuário","count":178},{"language":"tr","tag":"Kullanıcı Kılavuzları","count":178},{"language":"cn","tag":"用户指南","count":176},{"language":"en","tag":"Message channels","count":90},{"language":"es","tag":"Canales de mensajería","count":84},{"language":"fr","tag":"Canaux de messagerie","count":84},{"language":"ja","tag":"メッセージングチャネル","count":84},{"language":"ko","tag":"메시지 채널","count":84},{"language":"pt-BR","tag":"Canais de mensagem","count":84},{"language":"tr","tag":"Mesaj kanalları","count":84},{"language":"cn","tag":"消息渠道","count":83},{"language":"default","tag":"API Reference","count":68},{"language":"default","tag":"API reference","count":64},{"language":"en","tag":"Analytics \u0026 Integrations","count":53},{"language":"es","tag":"Analítica \u0026 Integraciones","count":52},{"language":"fr","tag":"Analyses et intégrations","count":52},{"language":"ja","tag":"分析 \u0026 統合","count":52},{"language":"ko","tag":"분석 \u0026 통합","count":52},{"language":"pt-BR","tag":"Análises \u0026 Integrações","count":52},{"language":"tr","tag":"Analitik ve Entegrasyonlar","count":52},{"language":"cn","tag":"分析和集成","count":51},{"language":"cn","tag":"开发者指南","count":48},{"language":"es","tag":"Guías del desarrollador","count":48},{"language":"fr","tag":"Guides développeur","count":48},{"language":"ja","tag":"開発者ガイド","count":48},{"language":"ko","tag":"개발자 가이드","count":48},{"language":"tr","tag":"Geliştirici Kılavuzları","count":48},{"language":"pt-BR","tag":"Guia de desenvolvedor","count":47},{"language":"en","tag":"Developer Guides","count":46},{"language":"en","tag":"Integrations","count":37},{"language":"es","tag":"Integraciones","count":37},{"language":"fr","tag":"Intégrations","count":37},{"language":"ja","tag":"統合","count":37},{"language":"ko","tag":"통합","count":37},{"language":"pt-BR","tag":"Integrações","count":37},{"language":"tr","tag":"Entegrasyonlar","count":37},{"language":"cn","tag":"集成","count":36},{"language":"en","tag":"Tutorials","count":35},{"language":"cn","tag":"推送通知","count":31},{"language":"cn","tag":"OneSignal 作为目的地","count":31},{"language":"en","tag":"Push","count":31},{"language":"en","tag":"OneSignal as destination","count":31},{"language":"es","tag":"Push notificaciones","count":31},{"language":"es","tag":"OneSignal como destino","count":31},{"language":"fr","tag":"Push","count":31},{"language":"fr","tag":"OneSignal comme destination","count":31},{"language":"ja","tag":"プッシュ通知","count":31},{"language":"ja","tag":"OneSignal as 宛先","count":31},{"language":"ko","tag":"푸시","count":31},{"language":"ko","tag":"OneSignal을 데이터 목적지로 사용","count":31},{"language":"pt-BR","tag":"Push notificações","count":31},{"language":"pt-BR","tag":"OneSignal como destino","count":31},{"language":"tr","tag":"Anlık bildirimler","count":31},{"language":"tr","tag":"OneSignal hedef","count":31},{"language":"cn","tag":"移动SDK","count":25},{"language":"en","tag":"Mobile SDKs","count":25},{"language":"es","tag":"SDKs móviles","count":25},{"language":"fr","tag":"SDK mobiles","count":25},{"language":"ja","tag":"モバイルSDK","count":25},{"language":"ko","tag":"모바일 SDKs","count":25},{"language":"pt-BR","tag":"SDKs móveis","count":25},{"language":"tr","tag":"Mobil SDK'lar","count":25},{"language":"cn","tag":"教程","count":24},{"language":"es","tag":"Tutoriales","count":24},{"language":"fr","tag":"Tutoriels","count":24},{"language":"ja","tag":"チュートリアル","count":24},{"language":"ko","tag":"튜토리얼","count":24},{"language":"pt-BR","tag":"Tutoriais","count":24},{"language":"tr","tag":"Eğitimler","count":24},{"language":"en","tag":"Email","count":19},{"language":"cn","tag":"移动SDK设置","count":18},{"language":"es","tag":"Configuración del SDK móvil","count":18},{"language":"fr","tag":"Configuration SDK mobile","count":18},{"language":"ja","tag":"モバイルSDKセットアップ","count":18},{"language":"ko","tag":"모바일 SDK 설정","count":18},{"language":"pt-BR","tag":"Configuração do SDK móvel","count":18},{"language":"tr","tag":"Mobil SDK kurulumu","count":18},{"language":"default","tag":"Messages","count":9},{"language":"default","tag":"Users","count":9},{"language":"default","tag":"Organization","count":9},{"language":"default","tag":"Journeys","count":8},{"language":"default","tag":"Deprecated","count":6},{"language":"default","tag":"Templates","count":6},{"language":"default","tag":"Subscriptions","count":6},{"language":"default","tag":"Segments","count":5}]},"assistantConfig":{"enableStarterQuestions":false,"deflection":{"enabled":true,"email":"support@onesignal.com","showHelpButton":true}},"basePath":"","hasChatPermissions":true,"hasWebMcpPermissions":true,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-v7-file-tree","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"pause-universal-search-reconcile","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"per-site-search-delta","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-private-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-nav-generations","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"byok-sep-25","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-agent-model-picker","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-updated-9-15","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"isAtlas":false,"googleFontsInlined":true},"customCss":[],"page":{"pagePath":"docs/en/segmentation","slug":"/docs/en/segmentation","pageMetadata":{"title":"Segments","description":"Create and manage dynamic user segments in OneSignal to target personalized messaging based on activity, location, tags, and more.","keywords":["segment limit","segment quota","how many segments","paused segments","cohorts","filters","custom event segment","event-based segment","user-based segment","combine segments","Segments are incompatible"],"href":"/docs/en/segmentation"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Create and manage dynamic user segments in OneSignal to target personalized messaging based on activity, location, tags, and more.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,ol:`ol`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{Card,CodeBlock,Columns,Frame,Heading,Note,OptimizedImage,Step,Steps,Tab,Table,Tabs,Warning}=_components;if(!Card)_missingMdxReference(`Card`,true);if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Columns)_missingMdxReference(`Columns`,true);if(!Frame)_missingMdxReference(`Frame`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Note)_missingMdxReference(`Note`,true);if(!OptimizedImage)_missingMdxReference(`OptimizedImage`,true);if(!Step)_missingMdxReference(`Step`,true);if(!Steps)_missingMdxReference(`Steps`,true);if(!Tab)_missingMdxReference(`Tab`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Tabs)_missingMdxReference(`Tabs`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsxs(_components.p,{children:[`A `,_jsx(_components.strong,{children:`segment`}),` is a dynamic group of users defined by filters on Subscription attributes, behavior, and custom data. OneSignal segments update automatically as users interact with your app or site, with no extra tracking required. Use segments to target messages, exclude audiences, and trigger Journeys.`]}),`\n`,_jsx(Note,{children:_jsxs(_components.p,{children:[`User-based segmentation is in beta. With it, segments contain users instead of Subscriptions. See `,_jsx(_components.a,{href:`/docs/en/user-based-segmentation`,children:`User-based segmentation`}),`.`]})}),`\n`,_jsxs(Warning,{children:[_jsxs(_components.p,{children:[`Push notifications, emails, and SMS messages are only sent to opted-in (subscribed) `,_jsx(_components.a,{href:`/docs/en/subscriptions`,children:`Subscriptions`}),`. The segment editor shows both subscribed and unsubscribed counts for transparency, but only subscribed Subscriptions receive messages when you target a segment. In-App Messages are displayed to all mobile Subscriptions, regardless of status.`]}),_jsxs(_components.p,{children:[`When used in Journeys, all Subscriptions in a segment, regardless of status, are evaluated to their respective `,_jsx(_components.a,{href:`/docs/en/users`,children:`Users`}),` and those users are entered into the Journey.`]})]}),`\n`,_jsx(Heading,{level:`2`,id:`segment-types`,children:`Segment types`}),`\n`,_jsx(_components.p,{children:`The OneSignal platform supports two main categories of segments:`}),`\n`,_jsx(Heading,{level:`3`,id:`subscription-based-segments`,children:`Subscription-based segments`}),`\n`,_jsx(_components.p,{children:`Subscription-based segments are built using filters on Subscription attributes, such as device type, language, or app version.`}),`\n`,_jsx(Heading,{level:`3`,id:`event-based-segments`,children:`Event-based segments`}),`\n`,_jsxs(_components.p,{children:[`Event-based segments are built using filters on user-level activity rather than individual Subscriptions. A segment is event-based when it includes `,_jsx(_components.a,{href:`/docs/en/message-events`,children:`message event`}),` or `,_jsx(_components.a,{href:`/docs/en/custom-events`,children:`Custom Event`}),` filters. You can add other filter types, such as tags and session filters, to the same segment. Examples include:`]}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:`When a user last opened an email, SMS, or push notification sent via OneSignal.`}),`\n`,_jsx(_components.li,{children:`Specific Custom Events tracked in your app or website.`}),`\n`]}),`\n`,_jsx(_components.p,{children:`An event-based segment includes all users who meet the criteria and automatically makes all of their Subscriptions eligible to be targeted, enabling richer audience definitions that can reach any of the user’s devices.`}),`\n`,_jsx(Heading,{level:`2`,id:`creating-segments`,children:`Creating segments`}),`\n`,_jsx(_components.p,{children:`Segments can be created in the dashboard, via the API, or by uploading a CSV. Target your audience by including and excluding segments when sending messages or building Journeys.`}),`\n`,_jsxs(Columns,{cols:3,children:[_jsx(Card,{title:`Dashboard`,icon:`display`,children:_jsxs(_components.p,{children:[`Create and manage segments from `,_jsx(_components.strong,{children:`Audience > Segments`}),`.`]})}),_jsx(Card,{title:`API`,icon:`code`,href:`/reference/create-segments`,children:_jsx(_components.p,{children:`Create segments programmatically using the Create Segment API.`})}),_jsx(Card,{title:`CSV Import`,icon:`file-csv`,href:`/docs/en/import`,children:_jsx(_components.p,{children:`Bulk-import Subscriptions and Tags via CSV, then build segments that match them.`})})]}),`\n`,_jsx(Heading,{level:`4`,id:`create-a-segment-in-the-dashboard`,children:`Create a segment in the dashboard`}),`\n`,_jsxs(Steps,{children:[_jsxs(Step,{title:`Go to Audience > Segments`,children:[_jsx(_components.p,{children:`Navigate to the Segments page in the dashboard.`}),_jsx(Frame,{caption:`Segments page`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segments-tab.png?fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=3cb693860c79428fe33135b5401c4941`,alt:`Segments page showing list of segments`,\"data-og-width\":`1277`,width:`1277`,\"data-og-height\":`1054`,height:`1054`,\"data-path\":`images/segments/segments-tab.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segments-tab.png?w=280\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=54bce57ef90c18cd435fd5fe9fdf34e8 280w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segments-tab.png?w=560\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=06ea14252e09ab062686616af1599298 560w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segments-tab.png?w=840\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=94d24aaa626ed6cdfb2f456324e5e51f 840w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segments-tab.png?w=1100\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=744fd2a2e444e68eeaa07573f996c1f6 1100w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segments-tab.png?w=1650\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=e5b854a813d525811b15a5be198541ed 1650w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segments-tab.png?w=2500\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=276a01219be002f36742b227ead9c54c 2500w`})})]}),_jsxs(Step,{title:`Click New Segment`,children:[_jsx(_components.p,{children:`Opens the segment creation interface.`}),_jsx(Frame,{caption:`Segment creation interface`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-creation-interface.png?fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=f9b2ec793a299ea442ce7a04194a4a31`,alt:`Segment creation interface showing filter options and segment name field`,\"data-og-width\":`1301`,width:`1301`,\"data-og-height\":`1061`,height:`1061`,\"data-path\":`images/segments/segment-creation-interface.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-creation-interface.png?w=280\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=7e958c0b2d704f2a4182eaf096371fb5 280w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-creation-interface.png?w=560\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=1e9a6b8e3d7168c4df4d602c917703fe 560w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-creation-interface.png?w=840\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=5e44157d7c99cb97b7d8e2ae3d8147d0 840w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-creation-interface.png?w=1100\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=597e921136e10265bd5203c8cce26e50 1100w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-creation-interface.png?w=1650\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=c5b0b199ed4caa37e1ab2938ccd976ce 1650w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-creation-interface.png?w=2500\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=636adda95b63bb4a17172dc64a324242 2500w`})})]}),_jsxs(Step,{title:`Add filters, name the segment, and click Create Segment`,children:[_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:`Add filters to define your audience criteria.`}),`\n`,_jsx(_components.li,{children:`Name the segment.`}),`\n`,_jsxs(_components.li,{children:[`Enter a `,_jsx(_components.strong,{children:`Description`}),` (optional). Click `,_jsx(_components.strong,{children:`Add description`}),` below the segment name (up to 255 characters).`]}),`\n`,_jsxs(_components.li,{children:[`Click `,_jsx(_components.strong,{children:`Create Segment`}),`.`]}),`\n`]}),_jsx(Frame,{caption:`Segment with filters and a name`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-creation-example.png?fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=13624ad1b90beedabcfa1ee6347529f0`,alt:`Segment creation interface with filters added and a segment name entered`,\"data-og-width\":`1320`,width:`1320`,\"data-og-height\":`589`,height:`589`,\"data-path\":`images/segments/segment-creation-example.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-creation-example.png?w=280\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=f0d80200193326067152a41629b862c0 280w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-creation-example.png?w=560\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=24b3c2b215f783613f8e8c7925d48769 560w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-creation-example.png?w=840\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=311678230fed2050f35340b9bff21dc7 840w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-creation-example.png?w=1100\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=8c3eaddaec67b20cc3f2a2103bee73e4 1100w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-creation-example.png?w=1650\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=257aa49bb4c0b13b5a836138b5c74e14 1650w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-creation-example.png?w=2500\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=856ccdc7fe6ffc9dda1e55b87fa60a09 2500w`})})]})]}),`\n`,_jsx(Heading,{level:`3`,id:`segment-logic-and-vs-or`,children:`Segment logic: AND vs OR`}),`\n`,_jsxs(_components.p,{children:[`Use `,_jsx(_components.strong,{children:`AND`}),` to combine filters that all must match. Use `,_jsx(_components.strong,{children:`OR`}),` to match any of multiple conditions.`]}),`\n`,_jsxs(Tabs,{children:[_jsxs(Tab,{title:`AND example`,id:`and-example`,children:[_jsx(_components.p,{children:`Create a segment of users who:`}),_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:`Have been active within the last 30 days`}),`\n`,_jsx(_components.li,{children:`Have at least 3 total sessions`}),`\n`]}),_jsx(Frame,{caption:`AND filter segment setup`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/and-filter-example.png?fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=c013ccef30256763df80d07d850a2962`,alt:`Segment with AND filters for users active within 30 days with at least 3 sessions`,\"data-og-width\":`1311`,width:`1311`,\"data-og-height\":`639`,height:`639`,\"data-path\":`images/segments/and-filter-example.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/and-filter-example.png?w=280\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=54942117db52834ca8346f84fecd7e3f 280w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/and-filter-example.png?w=560\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=5fd491f3e74496f87f009f33667e1752 560w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/and-filter-example.png?w=840\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=bc46712cf6f4e5b8c931ccb90534639c 840w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/and-filter-example.png?w=1100\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=a41a4f4070cd4fd2fc0fa83bad6e5170 1100w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/and-filter-example.png?w=1650\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=ff4eb6c533e4de42a5a9586141e89ff8 1650w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/and-filter-example.png?w=2500\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=afbb77dae3d815dbf6f17b6c9ceef2aa 2500w`})})]}),_jsxs(Tab,{title:`OR example`,id:`or-example`,children:[_jsx(_components.p,{children:`Create a segment of users who:`}),_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:`Have not returned in more than 7 days`}),`\n`,_jsx(_components.li,{children:`Have new Subscriptions created in the last 3 days`}),`\n`]}),_jsx(Frame,{caption:`OR clause segment configuration`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/or-filter-example.png?fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=82b594452c5432d927847e34e7d6f91d`,alt:`Segment with OR filter combining inactive users and new Subscriptions`,\"data-og-width\":`1298`,width:`1298`,\"data-og-height\":`672`,height:`672`,\"data-path\":`images/segments/or-filter-example.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/or-filter-example.png?w=280\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=bc96d165f5031b4fd883bb6fbedd433f 280w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/or-filter-example.png?w=560\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=86363837f936db6407d56f52bb30da6c 560w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/or-filter-example.png?w=840\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=4e99c60d274c37f29d15cd2d6e336e2b 840w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/or-filter-example.png?w=1100\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=35e663ce912ea9e06d2cf212505689ed 1100w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/or-filter-example.png?w=1650\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=4c89a5bea190bf7b15f689e6c8a00fe9 1650w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/or-filter-example.png?w=2500\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=176dbdad7c1e547bc8dd7942e02a501b 2500w`})})]})]}),`\n`,_jsx(Heading,{level:`2`,id:`filters`,children:`Filters`}),`\n`,_jsxs(_components.p,{children:[`Filters define which Subscriptions belong to a segment. You can combine multiple filters using `,_jsx(_components.strong,{children:`AND`}),` or `,_jsx(_components.strong,{children:`OR`}),` logic. If no filters are selected, the segment defaults to every user of your app.`]}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Filter`}),_jsx(_components.th,{children:`Description`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`First session`})}),_jsxs(_components.td,{children:[`The first time OneSignal saw this user active on any device, including email or SMS. Equivalent to the user’s `,_jsx(_components.code,{children:`created_at`}),` timestamp.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`Last session`})}),_jsx(_components.td,{children:`The last time OneSignal saw this user active on any SDK-tracked device.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`Session count`})}),_jsxs(_components.td,{children:[`Number of times Subscription opened the app or visited the site. See `,_jsx(_components.a,{href:`/docs/en/sessions`,children:`Sessions`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`Usage duration`})}),_jsx(_components.td,{children:`Total seconds the Subscription had your app/site open.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`Language`})}),_jsxs(_components.td,{children:[`User’s preferred language (based on device/browser). See `,_jsx(_components.a,{href:`/docs/en/multi-language-messaging`,children:`multi-language support`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`App version`})}),_jsxs(_components.td,{children:[`Pulled from Android `,_jsx(_components.code,{children:`versionCode`}),` or iOS `,_jsx(_components.code,{children:`CFBundleShortVersionString`}),`. Combine with `,_jsx(_components.strong,{children:`Device type`}),` to filter by different app versions per platform. See `,_jsx(_components.a,{href:`/docs/en/app-version-update`,children:`Target outdated app versions`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`Device type`})}),_jsx(_components.td,{children:`iOS, Android, Web Push (browser), Email, etc. Select multiple device types in one filter with “is any of”, or exclude them with “is not any of”.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`User tag`})}),_jsxs(_components.td,{children:[`Custom Tags you set via the SDK or API. See `,_jsx(_components.a,{href:`/docs/en/add-user-data-tags`,children:`Add Tags`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`Location`})}),_jsxs(_components.td,{children:[`Filter by radius from coordinates (lat/long). Requires at least 1 meter and up to 2 decimal places of precision. See `,_jsx(_components.a,{href:`/docs/en/mobile-sdk-reference#location`,children:`location permission`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`Country`})}),_jsx(_components.td,{children:`Based on last IP geolocation (ISO 3166-1 alpha-2 code).`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`Test users`})}),_jsxs(_components.td,{children:[`Users marked as `,_jsx(_components.a,{href:`/docs/en/test-users`,children:`Test Users`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`Message event`})}),_jsxs(_components.td,{children:[`Filter by `,_jsx(_components.a,{href:`/docs/en/message-events`,children:`message event`}),` (e.g., “clicked”, “delivered”, “failed”). See `,_jsx(_components.a,{href:`#message-event-filters`,children:`Message event filters`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`Custom event`})}),_jsxs(_components.td,{children:[`Filter by `,_jsx(_components.a,{href:`/docs/en/custom-events`,children:`custom event`}),` (e.g., “purchase”, “user login”). See `,_jsx(_components.a,{href:`#custom-event-filters`,children:`Custom event filters`}),`.`]})]})]})]}),`\n`,_jsx(Heading,{level:`3`,id:`event-based-filters`,children:`Event-based filters`}),`\n`,_jsx(_components.p,{children:`Event-based filters target users by the actions they take, both interactions with your OneSignal messages and custom events you send to OneSignal.`}),`\n`,_jsx(Heading,{level:`4`,id:`message-event-filters`,children:`Message event filters`}),`\n`,_jsxs(_components.p,{children:[`Message event filters target users based on their interaction with one of your messaging channels within a certain window. See `,_jsx(_components.a,{href:`/docs/en/message-events`,children:`Message events`}),` for the full event catalog and conceptual reference.`]}),`\n`,_jsx(Frame,{caption:`Message event filters`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/message_event_filters.png?fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=8ff30920fd89a72dd785f2949808e2c7`,alt:`Message event filter options showing channel, action, and time window selectors`,\"data-og-width\":`1295`,width:`1295`,\"data-og-height\":`581`,height:`581`,\"data-path\":`images/segments/message_event_filters.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/message_event_filters.png?w=280\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=d660904c9d3d9783c09205821307a67e 280w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/message_event_filters.png?w=560\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=b5dfb53ae95066c404427ed7f87b3e83 560w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/message_event_filters.png?w=840\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=eee2900b0968bc0576dce350e8c3ad89 840w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/message_event_filters.png?w=1100\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=65e0a94b8ef513d8d884d9ed9c4b6d1e 1100w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/message_event_filters.png?w=1650\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=ed82548fa9b02349ecc23d87ca5614a2 1650w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/message_event_filters.png?w=2500\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=623270ea1e3f053a82a0a37dd2196573 2500w`})}),`\n`,_jsx(_components.p,{children:`First select the messaging channel you want to filter on, then specify the action to track and whether the user has or has not performed that action.`}),`\n`,_jsxs(_components.p,{children:[`You can specify a minimum, maximum, or exact number of times the user must have performed the action, as well as a time window ranging from the last 24 hours to the last 90 days. Use the `,_jsx(_components.code,{children:`between`}),` option to define a custom start and end range (in days ago).`]}),`\n`,_jsx(Heading,{level:`4`,id:`trackable-interactions-by-channel`,children:`Trackable interactions by channel`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Channel`}),_jsx(_components.th,{children:`Trackable interactions`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Push`}),_jsx(_components.td,{children:`Delivered, Confirmed Receipt, Clicked, Failed`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`SMS`}),_jsx(_components.td,{children:`Delivered, Read, Failed`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Email`}),_jsx(_components.td,{children:`Delivered, Opened, Clicked, Bounced, Failed, Suppressed, Reported as spam`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`In-App`}),_jsx(_components.td,{children:`Impression, Clicked`})]})]})]}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[`Segments with message event filters are event-based. Outside `,_jsx(_components.a,{href:`/docs/en/journeys-overview`,children:`Journeys`}),`, you cannot include or exclude them with segments that have no message event or custom event filters. See `,_jsx(_components.a,{href:`#can-i-combine-custom-event-or-message-event-segments-with-other-segments`,children:`Can I combine custom event or message event segments with other segments?`}),` for the dashboard and API rules.`]})}),`\n`,_jsx(Heading,{level:`4`,id:`message-event-retention`,children:`Message event retention`}),`\n`,_jsx(_components.p,{children:`The amount of time message event data is retained depends on your plan. The dashboard time window selector shows up to 90 days, but data beyond your plan’s retention period will not return results.`}),`\n`,_jsx(Card,{title:`Retention by plan`,icon:`clock`,href:`/docs/en/message-events#retention`,children:_jsx(_components.p,{children:`Free, Growth, Pro, and Enterprise retention windows for message event data.`})}),`\n`,_jsx(Heading,{level:`3`,id:`custom-event-filters`,children:`Custom event filters`}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.a,{href:`/docs/en/custom-events`,children:`Custom Event`}),` filters let you target users based on meaningful actions they have taken in your app, website, or external systems.`]}),`\n`,_jsxs(_components.p,{children:[`Custom event filters read stored events. Turn on `,_jsx(_components.a,{href:`/docs/en/custom-event-storage`,children:`storage`}),` for each event you segment on.`]}),`\n`,_jsx(Frame,{caption:`Custom event filters`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/custom_event_filters.png?fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=99925f2d8c574a94b54817e7a8aae24c`,alt:`Custom event filter options showing event type and property selectors`,\"data-og-width\":`1305`,width:`1305`,\"data-og-height\":`757`,height:`757`,\"data-path\":`images/segments/custom_event_filters.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/custom_event_filters.png?w=280\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=954be354f20e9ece5eb856d3253cae67 280w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/custom_event_filters.png?w=560\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=4acf40ab29bc3eb07488535676fed7ec 560w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/custom_event_filters.png?w=840\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=0b4ff27b955ae849c5b41f852d751934 840w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/custom_event_filters.png?w=1100\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=45f2cb3cc6c31ba11f5349de20d17926 1100w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/custom_event_filters.png?w=1650\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=e8461b054458a99438067402998c281f 1650w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/custom_event_filters.png?w=2500\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=44b49425cff0fc4e5d68489b8231b663 2500w`})}),`\n`,_jsx(_components.p,{children:`Start by selecting:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:`The event name you want to filter on.`}),`\n`,_jsxs(_components.li,{children:[`Whether the user `,_jsx(_components.code,{children:`has`}),` or `,_jsx(_components.code,{children:`has not`}),` performed that action.`]}),`\n`,_jsx(_components.li,{children:`The minimum, maximum, or exact number of times the action must be performed.`}),`\n`,_jsxs(_components.li,{children:[`A time window during which the action must (or must not) occur. Choose a preset range or define a custom window using the `,_jsx(_components.code,{children:`between`}),` option (start and end in days ago).`]}),`\n`]}),`\n`,_jsx(_components.p,{children:`After specifying the event, you can optionally filter on specific or multiple properties:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`all`}),`: applies an AND condition across properties.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`at least one`}),`: applies an OR condition.`]}),`\n`]}),`\n`,_jsxs(_components.p,{children:[`Then set the properties you want to filter on using `,_jsx(_components.code,{children:`dot notation`}),`.`]}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[`Custom Events are represented as `,_jsx(_components.a,{href:`https://www.w3schools.com/js/js_json.asp`,children:`JSON Objects`}),`.`]}),`\n`,_jsxs(_components.li,{children:[`See `,_jsx(_components.a,{href:`/docs/en/custom-events#what-are-custom-events`,children:`Custom Events`}),` for more details.`]}),`\n`]}),`\n`,_jsx(Heading,{level:`4`,id:`example`,children:`Example`}),`\n`,_jsx(_components.p,{children:`Given the following Custom Event:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`13`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`13`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"events\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"cart_updated\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"properties\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"product_name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"24 Pack of Acorns\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"product_price\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`12.99`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"product_quantity\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`2`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"external_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"ID_OF_THE_USER\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`You can filter by:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`product_name`}),` → to target users with product name `,_jsx(_components.code,{children:`24 Pack of Acorns`}),`.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`product_price`}),` → to target users with a product price greater than `,_jsx(_components.code,{children:`10`}),`.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`product_quantity`}),` → to target users with a product quantity of `,_jsx(_components.code,{children:`2`}),` or more.`]}),`\n`]}),`\n`,_jsx(Frame,{caption:`Custom event filter example`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/custom_event_filter_example.png?fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=3b5b12a65bd8528e097cf1e46c185ff5`,alt:`Custom event filter example showing product name, image, price, quantity, and cart URL`,\"data-og-width\":`1299`,width:`1299`,\"data-og-height\":`721`,height:`721`,\"data-path\":`images/segments/custom_event_filter_example.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/custom_event_filter_example.png?w=280\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=8f8df416242ff9b68be9882f6add5d8b 280w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/custom_event_filter_example.png?w=560\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=be2600e612f462823b05b8de07ca1b12 560w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/custom_event_filter_example.png?w=840\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=6263384adc0797a314b2326c3fcecb0d 840w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/custom_event_filter_example.png?w=1100\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=8eade56907f0a4ea03127c9bcc93f390 1100w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/custom_event_filter_example.png?w=1650\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=7d04cef50a9ec15433748c58564a0822 1650w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/custom_event_filter_example.png?w=2500\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=6eb02ec3efd7efd0a3db9461ee521ab1 2500w`})}),`\n`,_jsx(_components.p,{children:`You can add other filter types to the same segment, including message events, tags, and session filters.`}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[`Segments with custom event filters are event-based. Outside `,_jsx(_components.a,{href:`/docs/en/journeys-overview`,children:`Journeys`}),`, you cannot include or exclude them with segments that have no message event or custom event filters. See `,_jsx(_components.a,{href:`#can-i-combine-custom-event-or-message-event-segments-with-other-segments`,children:`Can I combine custom event or message event segments with other segments?`}),` for the dashboard and API rules.`]})}),`\n`,_jsx(Card,{title:`Custom event best practices`,icon:`lightbulb`,href:`/docs/en/custom-event-best-practices`,children:_jsx(_components.p,{children:`Shape event properties for Segment filters and see an example Segment for each event.`})}),`\n`,_jsx(Heading,{level:`2`,id:`audience-counts`,children:`Audience counts`}),`\n`,_jsx(_components.p,{children:`The segment editor shows how many subscribed and unsubscribed Subscriptions are in your segment, with a breakdown by channel (push, email, and SMS).`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Subscribed`}),` Subscriptions are opted in and will receive messages when you target this segment.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Unsubscribed`}),` Subscriptions match your segment filters but are opted out and will not receive messages.`]}),`\n`]}),`\n`,_jsx(_components.p,{children:`The channel breakdown lets you see reachable vs. unreachable Subscriptions per channel, which helps you understand which channels will be most effective before you build a message or Journey.`}),`\n`,_jsx(Frame,{caption:`Audience counts`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/audience_counts.png?fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=f945aabbb335d53054b058f41bfad527`,alt:`Audience counts showing subscribed and unsubscribed counts by channel`,\"data-og-width\":`1309`,width:`1309`,\"data-og-height\":`1089`,height:`1089`,\"data-path\":`images/segments/audience_counts.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/audience_counts.png?w=280\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=1ad30dee9ec704415b30259ad0913b4d 280w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/audience_counts.png?w=560\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=24daf19e0b134f4e350f9baa27dea366 560w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/audience_counts.png?w=840\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=3f221ba8157cebba18116765459ecd0e 840w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/audience_counts.png?w=1100\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=eaec9597bd9b5aae677c9e44021ee83b 1100w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/audience_counts.png?w=1650\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=2751450a883adeadbf966913470f4c1c 1650w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/audience_counts.png?w=2500\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=1abf76933264f1b471897d7c54789202 2500w`})}),`\n`,_jsx(Heading,{level:`3`,id:`exact-counts-and-estimates`,children:`Exact counts and estimates`}),`\n`,_jsx(_components.p,{children:`OneSignal always returns a count within approximately 15 seconds. Whenever possible within that time limit, you will see an exact count. For large or complex segments where exact counts can take a long time to compute, an estimate is shown instead.`}),`\n`,_jsx(_components.p,{children:`Estimates are labeled to make clear they are not exact:`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Segment size`}),_jsx(_components.th,{children:`Format`}),_jsx(_components.th,{children:`Example`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Above 10,000`}),_jsx(_components.td,{children:`Count with margin of error`}),_jsx(_components.td,{\"data-numeric\":`true`,children:_jsx(_components.code,{children:`140,000 +/- 5,000`})})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Below 10,000`}),_jsx(_components.td,{children:`Less-than value`}),_jsx(_components.td,{\"data-numeric\":`true`,children:_jsx(_components.code,{children:`\u003c4,800`})})]})]})]}),`\n`,_jsx(_components.p,{children:`Both formats are rounded to signal the number is approximate. Estimates will never display as 0: if your segment has very few members, the estimate reflects a small non-zero estimate to avoid implying the segment is empty when records may exist.`}),`\n`,_jsx(Note,{children:_jsx(_components.p,{children:`Segments with message event or custom event filters show counts on the Segments page once they finish processing. The segment editor doesn’t show a live estimate for them.`})}),`\n`,_jsx(Heading,{level:`2`,id:`managing-segments`,children:`Managing segments`}),`\n`,_jsx(_components.p,{children:`When viewing your Segments in the dashboard, you can:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`View Subscriptions:`}),` See which `,_jsx(_components.a,{href:`/docs/en/subscriptions`,children:`Subscriptions`}),` are in the segment.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Copy segment ID:`}),` Copy the segment ID to use in the API.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Edit:`}),` Change filters or name.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Pause / Resume:`}),` Pause a segment to keep its configuration without it counting toward your `,_jsx(_components.a,{href:`#segment-limit`,children:`Segment limit`}),`. Targeting a paused segment will fail.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Set as default:`}),` Set a default segment to be auto-selected when sending a new message. This helps reduce targeting mistakes and save time.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Duplicate:`}),` Copy a segment’s filters to create a new one.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`View Audit Logs:`}),` See the `,_jsx(_components.a,{href:`/docs/en/audit-logs`,children:`audit logs`}),` for who may have changed a segment and when.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Delete:`}),` Delete the segment.`]}),`\n`]}),`\n`,_jsx(Heading,{level:`3`,id:`segment-limit`,children:`Segment limit`}),`\n`,_jsxs(_components.p,{children:[`Your plan determines how many segments you can have at one time. Only `,_jsx(_components.strong,{children:`active`}),` (non-paused) segments count toward this limit. Paused segments stay in your account but do not count, so you can pause segments you no longer use instead of deleting them.`]}),`\n`,_jsx(_components.p,{children:`To free up capacity:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Pause`}),` segments you may want to use again later. The filter configuration is preserved and the segment can be resumed at any time.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Delete`}),` segments you no longer need.`]}),`\n`]}),`\n`,_jsxs(_components.p,{children:[`See the `,_jsx(_components.a,{href:`https://onesignal.com/pricing`,children:`pricing page`}),` for the segment limit on each plan.`]}),`\n`,_jsx(Heading,{level:`3`,id:`deleting-segments`,children:`Deleting segments`}),`\n`,_jsxs(_components.p,{children:[`Deleting a segment removes it from your list of segments. It does `,_jsx(_components.strong,{children:`not`}),` delete the users inside it. To delete the users inside a segment, see `,_jsx(_components.a,{href:`/docs/en/delete-users`,children:`Delete Users`}),`.`]}),`\n`,_jsxs(Tabs,{children:[_jsxs(Tab,{title:`Dashboard`,id:`dashboard`,children:[_jsxs(_components.ol,{children:[`\n`,_jsxs(_components.li,{children:[`Go to `,_jsx(_components.strong,{children:`Audience > Segments`})]}),`\n`,_jsx(_components.li,{children:`Click the three-dot menu next to a segment`}),`\n`,_jsxs(_components.li,{children:[`Select `,_jsx(_components.strong,{children:`Delete`})]}),`\n`]}),_jsx(Frame,{caption:`Segment options menu`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-menu.png?fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=50001e1271a9ce9067a81a4e07370517`,alt:`Three-dot options menu on a segment showing Edit, Pause, Duplicate, and Delete actions`,\"data-og-width\":`1290`,width:`1290`,\"data-og-height\":`1055`,height:`1055`,\"data-path\":`images/segments/segment-menu.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-menu.png?w=280\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=0626602fcb42fe3decc54f17c3f77d9d 280w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-menu.png?w=560\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=525733219fe6650bf482da65de68b40d 560w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-menu.png?w=840\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=27b1d37fade09912fb820ebcd4bebc3b 840w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-menu.png?w=1100\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=c046a6291f7569f7fa423bf2697763b2 1100w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-menu.png?w=1650\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=6a1eb1774387df6a028791b0ab5b413c 1650w, https://mintcdn.com/onesignal/BIUS_wdfwITxcuxQ/images/segments/segment-menu.png?w=2500\u0026fit=max\u0026auto=format\u0026n=BIUS_wdfwITxcuxQ\u0026q=85\u0026s=5e4bb65b456e794655ddafd61808b195 2500w`})})]}),_jsx(Tab,{title:`API`,id:`api`,children:_jsxs(_components.p,{children:[`Use the `,_jsx(_components.a,{href:`/reference/delete-segments`,children:`Delete Segment API`}),`. This only removes the segment definition, not the users inside it.`]})})]}),`\n`,_jsx(Heading,{level:`2`,id:`faq`,children:`FAQ`}),`\n`,_jsx(Heading,{level:`3`,id:`can-i-manually-add-specific-users-to-a-segment`,children:`Can I manually add specific users to a segment?`}),`\n`,_jsx(_components.p,{children:`Not directly. Segments are dynamic groups defined by filters, so there is no option to hand-pick individual members. To group specific users:`}),`\n`,_jsxs(_components.ol,{children:[`\n`,_jsxs(_components.li,{children:[`Add a shared `,_jsx(_components.a,{href:`/docs/en/add-user-data-tags`,children:`Tag`}),` to those users via the SDK, the API, or a `,_jsx(_components.a,{href:`/docs/en/import`,children:`CSV import`}),`.`]}),`\n`,_jsxs(_components.li,{children:[`Create a segment with a `,_jsx(_components.strong,{children:`User tag`}),` filter matching that tag.`]}),`\n`]}),`\n`,_jsxs(_components.p,{children:[`The `,_jsx(_components.a,{href:`/docs/en/import#review-and-confirm`,children:`CSV importer`}),` can also do both steps at once: enable `,_jsx(_components.strong,{children:`Automatically create a Segment`}),` on the Review screen to tag every imported user and create a matching segment.`]}),`\n`,_jsxs(_components.p,{children:[`To test with a small group, such as your own team’s devices, mark those devices as `,_jsx(_components.a,{href:`/docs/en/test-users`,children:`Test Users`}),` and create a segment with the `,_jsx(_components.strong,{children:`Test Users`}),` filter.`]}),`\n`,_jsx(Heading,{level:`3`,id:`how-do-i-add-myself-to-a-segment`,children:`How do I add myself to a segment?`}),`\n`,_jsx(_components.p,{children:`Set yourself as a Test User or add a custom Tag, then create a segment that targets it.`}),`\n`,_jsxs(_components.ol,{children:[`\n`,_jsxs(_components.li,{children:[`Find your Subscriptions using your `,_jsx(_components.a,{href:`/docs/en/users`,children:`External ID`}),`.`]}),`\n`,_jsxs(_components.li,{children:[`Either:`,`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[`Set yourself as a `,_jsx(_components.a,{href:`/docs/en/test-users`,children:`Test User`})]}),`\n`,_jsxs(_components.li,{children:[`Add a custom `,_jsx(_components.a,{href:`/docs/en/add-user-data-tags`,children:`Tag`})]}),`\n`]}),`\n`]}),`\n`,_jsxs(_components.li,{children:[`Create a segment using the `,_jsx(_components.strong,{children:`Test Users`}),` filter or the Tag.`]}),`\n`]}),`\n`,_jsx(Heading,{level:`3`,id:`do-segment-counts-include-opted-out-users`,children:`Do segment counts include opted-out users?`}),`\n`,_jsx(_components.p,{children:`Yes. The segment editor shows counts for both subscribed and unsubscribed Subscriptions. Subscribed Subscriptions are opted in and will receive messages. Unsubscribed Subscriptions match your filters but are opted out and will not receive messages.`}),`\n`,_jsx(_components.p,{children:`Only subscribed Subscriptions are targeted when you send a message.`}),`\n`,_jsx(_components.p,{children:`When used in Journeys and in-app messages, segments include both subscribed and unsubscribed Subscriptions.`}),`\n`,_jsx(Heading,{level:`3`,id:`are-segment-counts-always-accurate`,children:`Are segment counts always accurate?`}),`\n`,_jsx(_components.p,{children:`OneSignal always returns a count within approximately 15 seconds. For smaller or simpler segments, this is an exact count. For larger or more complex segments, an estimate is shown instead.`}),`\n`,_jsxs(_components.p,{children:[`Estimates are clearly labeled with their precision. See `,_jsx(_components.a,{href:`#audience-counts`,children:`Audience counts`}),` for details on how estimates are formatted and what they mean.`]}),`\n`,_jsx(Heading,{level:`3`,id:`can-i-combine-custom-event-or-message-event-segments-with-other-segments`,children:`Can I combine custom event or message event segments with other segments?`}),`\n`,_jsx(_components.p,{children:`Yes, with some send-time limits. A custom event segment can include other filter types such as message events, tags, and session filters.`}),`\n`,_jsxs(_components.p,{children:[`When sending messages outside of `,_jsx(_components.a,{href:`/docs/en/journeys-overview`,children:`Journeys`}),`, you cannot include or exclude event-based segments (custom event or message event) with segments that have no event filters. In the dashboard, you can send custom event segments and message event segments together. The API accepts message event segments only with other message event segments, and custom event segments only with other custom event segments.`]}),`\n`,_jsx(_components.p,{children:`Inside Journeys, you can combine event-based segments with any other segments.`}),`\n`,_jsx(Heading,{level:`3`,id:`does-the-segment-limit-count-paused-segments`,children:`Does the segment limit count paused segments?`}),`\n`,_jsxs(_components.p,{children:[`No. Only active (non-paused) segments count toward your plan’s segment limit. Pause segments you no longer use to free up capacity without losing the filter configuration. See `,_jsx(_components.a,{href:`#segment-limit`,children:`Segment limit`}),` for details.`]}),`\n`,_jsx(Heading,{level:`2`,id:`related-pages`,children:`Related pages`}),`\n`,_jsxs(Columns,{cols:2,children:[_jsx(Card,{title:`User-based segmentation`,icon:`users`,href:`/docs/en/user-based-segmentation`,children:_jsx(_components.p,{children:`Beta: segments of users that work across every channel.`})}),_jsx(Card,{title:`Subscriptions`,icon:`address-book`,href:`/docs/en/subscriptions`,children:_jsx(_components.p,{children:`The push, email, and SMS records segments target.`})}),_jsx(Card,{title:`Add user data tags`,icon:`tags`,href:`/docs/en/add-user-data-tags`,children:_jsx(_components.p,{children:`Tag users with custom data so segments can filter on it.`})}),_jsx(Card,{title:`Custom Events`,icon:`bolt`,href:`/docs/en/custom-events`,children:_jsx(_components.p,{children:`Send user actions to OneSignal for use in segments and Journeys.`})}),_jsx(Card,{title:`Message events`,icon:`envelope-open`,href:`/docs/en/message-events`,children:_jsx(_components.p,{children:`Per-user record of message interactions, the basis of message event filters.`})}),_jsx(Card,{title:`Journeys overview`,icon:`route`,href:`/docs/en/journeys-overview`,children:_jsx(_components.p,{children:`Trigger automated workflows from segment membership.`})}),_jsx(Card,{title:`Import users`,icon:`file-csv`,href:`/docs/en/import`,children:_jsx(_components.p,{children:`Bulk-import users and Tags via CSV.`})})]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Segments","description":"Create and manage dynamic user segments in OneSignal to target personalized messaging based on activity, location, tags, and more.","keywords":["segment limit","segment quota","how many segments","paused segments","cohorts","filters","custom event segment","event-based segment","user-based segment","combine segments","Segments are incompatible"],"href":"/docs/en/segmentation"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Segment types","slug":"segment-types","depth":2,"children":[{"title":"Subscription-based segments","slug":"subscription-based-segments","depth":3,"children":[]},{"title":"Event-based segments","slug":"event-based-segments","depth":3,"children":[]}]},{"title":"Creating segments","slug":"creating-segments","depth":2,"children":[{"title":"Create a segment in the dashboard","slug":"create-a-segment-in-the-dashboard","depth":4,"children":[]},{"title":"Segment logic: AND vs OR","slug":"segment-logic-and-vs-or","depth":3,"children":[]}]},{"title":"Filters","slug":"filters","depth":2,"children":[{"title":"Event-based filters","slug":"event-based-filters","depth":3,"children":[]},{"title":"Message event filters","slug":"message-event-filters","depth":4,"children":[]},{"title":"Trackable interactions by channel","slug":"trackable-interactions-by-channel","depth":4,"children":[]},{"title":"Message event retention","slug":"message-event-retention","depth":4,"children":[]},{"title":"Custom event filters","slug":"custom-event-filters","depth":3,"children":[]},{"title":"Example","slug":"example","depth":4,"children":[]}]},{"title":"Audience counts","slug":"audience-counts","depth":2,"children":[{"title":"Exact counts and estimates","slug":"exact-counts-and-estimates","depth":3,"children":[]}]},{"title":"Managing segments","slug":"managing-segments","depth":2,"children":[{"title":"Segment limit","slug":"segment-limit","depth":3,"children":[]},{"title":"Deleting segments","slug":"deleting-segments","depth":3,"children":[]}]},{"title":"FAQ","slug":"faq","depth":2,"children":[{"title":"Can I manually add specific users to a segment?","slug":"can-i-manually-add-specific-users-to-a-segment","depth":3,"children":[]},{"title":"How do I add myself to a segment?","slug":"how-do-i-add-myself-to-a-segment","depth":3,"children":[]},{"title":"Do segment counts include opted-out users?","slug":"do-segment-counts-include-opted-out-users","depth":3,"children":[]},{"title":"Are segment counts always accurate?","slug":"are-segment-counts-always-accurate","depth":3,"children":[]},{"title":"Can I combine custom event or message event segments with other segments?","slug":"can-i-combine-custom-event-or-message-event-segments-with-other-segments","depth":3,"children":[]},{"title":"Does the segment limit count paused segments?","slug":"does-the-segment-limit-count-paused-segments","depth":3,"children":[]}]},{"title":"Related pages","slug":"related-pages","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":["/_mintlify/custom/onesignal/e069c1b9f3157e14/hotjar-koala.js","/_mintlify/custom/onesignal/3e5d03885ab32f49/intercom.js","/_mintlify/custom/onesignal/dbb7af4794d1b586/munchkin-marketo.js"],"subdomain":"onesignal","siteName":"OneSignal","title":"Segments - OneSignal","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{"en":{"href":"/docs/en/segmentation","matchLevel":0},"cn":{"href":"/docs/cn/segmentation","matchLevel":1},"ko":{"href":"/docs/ko/segmentation","matchLevel":1},"ja":{"href":"/docs/ja/segmentation","matchLevel":1},"tr":{"href":"/docs/tr/segmentation","matchLevel":1},"pt-BR":{"href":"/docs/pt-BR/segmentation","matchLevel":1},"es":{"href":"/docs/es/segmentation","matchLevel":1},"fr":{"href":"/docs/fr/segmentation","matchLevel":1}}},"lastModified":"2026-10-27T21:58:43.255Z","originalFileLocation":"docs/en/segmentation.mdx","locale":"en"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Create and manage dynamic user segments in OneSignal to target personalized messaging based on activity, location, tags, and more.\">\u003cmeta data-mint-head name=\"application-name\" content=\"OneSignal\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Segments - OneSignal\">\u003cmeta data-mint-head property=\"og:description\" content=\"Create and manage dynamic user segments in OneSignal to target personalized messaging based on activity, location, tags, and more.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"OneSignal\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://documentation.onesignal.com/docs/en/segmentation\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://onesignal.mintlify.app/_mintlify/api/og/v2?division=Audience+%26+events\u0026amp;title=Segments\u0026amp;description=Create+and+manage+dynamic+user+segments+in+OneSignal+to+target+personalized+messaging+based+on+activity%2C+location%2C+tags%2C+and+more.\u0026amp;theme=8d648f04f85028b307bd669b\u0026amp;signature=64225147eab98b9314ddda295f02ca1a8db120b4400075bb734934ab3e4fb02b\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Segments - OneSignal\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Create and manage dynamic user segments in OneSignal to target personalized messaging based on activity, location, tags, and more.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://onesignal.mintlify.app/_mintlify/api/og/v2?division=Audience+%26+events\u0026amp;title=Segments\u0026amp;description=Create+and+manage+dynamic+user+segments+in+OneSignal+to+target+personalized+messaging+based+on+activity%2C+location%2C+tags%2C+and+more.\u0026amp;theme=8d648f04f85028b307bd669b\u0026amp;signature=64225147eab98b9314ddda295f02ca1a8db120b4400075bb734934ab3e4fb02b\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/onesignal/eCiRydtW5fLfLRWp/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"OneSignal Docs\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#3A3DB3\">\u003clink data-mint-head rel=\"canonical\" href=\"https://documentation.onesignal.com/docs/en/segmentation\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/docs/en/segmentation.md\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"en\" href=\"https://documentation.onesignal.com/docs/en/segmentation\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"zh\" href=\"https://documentation.onesignal.com/docs/cn/segmentation\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"ko\" href=\"https://documentation.onesignal.com/docs/ko/segmentation\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"ja\" href=\"https://documentation.onesignal.com/docs/ja/segmentation\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"tr\" href=\"https://documentation.onesignal.com/docs/tr/segmentation\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"pt-BR\" href=\"https://documentation.onesignal.com/docs/pt-BR/segmentation\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"es\" href=\"https://documentation.onesignal.com/docs/es/segmentation\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"fr\" href=\"https://documentation.onesignal.com/docs/fr/segmentation\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"x-default\" href=\"https://documentation.onesignal.com/docs/en/segmentation\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://documentation.onesignal.com/#organization\",\"name\":\"OneSignal\",\"url\":\"https://documentation.onesignal.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/onesignal/yJcueeDCO7UpHnnY/logo/OneSignal-Logo.svg?fit=max\u0026auto=format\u0026n=yJcueeDCO7UpHnnY\u0026q=85\u0026s=1fcfb6fef6d820fd9d99c74850711107\"}},{\"@type\":\"WebSite\",\"@id\":\"https://documentation.onesignal.com#website\",\"name\":\"OneSignal\",\"url\":\"https://documentation.onesignal.com\",\"publisher\":{\"@id\":\"https://documentation.onesignal.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://documentation.onesignal.com/docs/en/segmentation#webpage\",\"url\":\"https://documentation.onesignal.com/docs/en/segmentation\",\"name\":\"Segments\",\"description\":\"Create and manage dynamic user segments in OneSignal to target personalized messaging based on activity, location, tags, and more.\",\"dateModified\":\"2026-10-27T21:58:43.255Z\",\"isPartOf\":{\"@id\":\"https://documentation.onesignal.com#website\"},\"breadcrumb\":{\"@id\":\"https://documentation.onesignal.com/docs/en/segmentation#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://documentation.onesignal.com/docs/en/segmentation#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"OneSignal\",\"item\":\"https://documentation.onesignal.com\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Segments\",\"item\":\"https://documentation.onesignal.com/docs/en/segmentation\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://documentation.onesignal.com/docs/en/segmentation#article\",\"headline\":\"Segments\",\"name\":\"Segments\",\"description\":\"Create and manage dynamic user segments in OneSignal to target personalized messaging based on activity, location, tags, and more.\",\"url\":\"https://documentation.onesignal.com/docs/en/segmentation\",\"mainEntityOfPage\":{\"@id\":\"https://documentation.onesignal.com/docs/en/segmentation#webpage\"},\"dateModified\":\"2026-10-27T21:58:43.255Z\",\"keywords\":\"segment limit, segment quota, how many segments, paused segments, cohorts, filters, custom event segment, event-based segment, user-based segment, combine segments, Segments are incompatible\",\"publisher\":{\"@id\":\"https://documentation.onesignal.com/#organization\"},\"isPartOf\":{\"@id\":\"https://documentation.onesignal.com#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"OneSignal\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"OneSignal","nav":{"global":null,"languages":[{"language":"en","tabs":[{"tab":"Home","pages":[{"title":"Home","href":"/docs/en/home"}]},{"tab":"User Guides","groups":[{"group":"First steps \u0026 settings","pages":[{"title":"Getting started with OneSignal","href":"/docs/en/quickstart-guide"},{"group":"OneSignal dashboard","pages":[{"title":"Apps, Organizations, \u0026 Accounts","href":"/docs/en/apps-organizations"},{"title":"Team members","href":"/docs/en/manage-team-members"},{"title":"Keys \u0026 IDs","href":"/docs/en/keys-and-ids"},{"title":"Audit logs","href":"/docs/en/audit-logs"},{"title":"Usage \u0026 billing","href":"/docs/en/billing-faq"},{"title":"Disabled apps \u0026 organizations","href":"/docs/en/disabled-apps"}]},{"title":"Migrating to OneSignal","href":"/docs/en/migrating-to-onesignal"}]},{"group":"Message channels","pages":[{"title":"Channel setup","href":"/docs/en/channel-setup"},{"group":"Push","pages":[{"title":"Push overview","href":"/docs/en/push"},{"group":"Mobile push","pages":[{"title":"Mobile push setup","href":"/docs/en/mobile-push-setup"},{"title":"Prompt for push permissions","href":"/docs/en/prompt-for-push-permissions"},{"title":"iOS provisional push notifications","href":"/docs/en/ios-provisional-push-notifications"},{"title":"Android notification categories","href":"/docs/en/android-notification-categories"},{"title":"Data \u0026 background notifications","href":"/docs/en/data-notifications"},{"title":"VoIP push notifications","href":"/docs/en/voip-notifications"}]},{"group":"Web push","pages":[{"title":"Web push setup","href":"/docs/en/web-push-setup"},{"title":"Web permission prompts","href":"/docs/en/permission-requests"},{"title":"Web push FAQ","href":"/docs/en/web-push-setup-faq"},{"title":"Web push browser behavior","href":"/docs/en/browser-behavior-and-unsubscribes"},{"title":"OneSignal WordPress plugin setup for web push","href":"/docs/en/wordpress"},{"title":"WordPress troubleshooting","href":"/docs/en/troubleshooting-wordpress-web-push"},{"title":"Shopify web push integration","href":"/docs/en/shopify"}]},{"group":"Push features","pages":[{"title":"Notification icons","href":"/docs/en/notification-icons"},{"title":"Notification images \u0026 rich media","href":"/docs/en/rich-media"},{"title":"Notification sounds","href":"/docs/en/notification-sounds"},{"title":"Notification badges","href":"/docs/en/badges"},{"title":"Action buttons for push notifications","href":"/docs/en/action-buttons"},{"title":"Push frequency capping","href":"/docs/en/frequency-capping"},{"title":"Push throttling","href":"/docs/en/throttling"},{"title":"iOS: Focus modes and interruption levels","href":"/docs/en/ios-focus-modes-and-interruption-levels"},{"title":"iOS: Relevance score","href":"/docs/en/ios-relevance-score"}]},{"group":"Push analytics \u0026 troubleshooting","pages":[{"title":"Push message reports","href":"/docs/en/push-notification-message-reports"},{"title":"Confirmed receipt","href":"/docs/en/confirmed-delivery"},{"title":"Notification click-through rate (CTR)","href":"/docs/en/notification-ctr"},{"title":"Mobile push: Notifications not shown or delayed","href":"/docs/en/notifications-show-successful-but-are-not-being-shown"},{"title":"Web push: Notifications not shown","href":"/docs/en/notifications-not-shown-web-push"},{"title":"Notification Images Not Showing","href":"/docs/en/notification-images-not-showing"},{"title":"Duplicated notifications","href":"/docs/en/duplicated-notifications"},{"title":"FCM expired token FAQ","href":"/docs/en/fcm-expired-token-faq"}]}]},{"group":"In-app messages","pages":[{"title":"In-app overview","href":"/docs/en/in-app-messages-setup"},{"title":"In-app triggers","href":"/docs/en/iam-triggers"},{"title":"In-app click actions","href":"/docs/en/iam-click-actions"},{"group":"In-app design","pages":[{"title":"Design in-app messages with drag-and-drop","href":"/docs/en/design-your-in-app-message"},{"title":"Design in-app messages with HTML","href":"/docs/en/design-your-in-app-message-with-html"},{"title":"In-app message templates \u0026 quickstarts","href":"/docs/en/in-app-html-templates"},{"title":"In-app message JavaScript API reference","href":"/docs/en/in-app-message-api"}]},{"title":"In-app message reports","href":"/docs/en/in-app-message-reports"},{"title":"In-app troubleshooting","href":"/docs/en/in-app-message-troubleshooting"}]},{"group":"Email","pages":[{"title":"Email overview","href":"/docs/en/email-messaging"},{"group":"Email setup","pages":[{"title":"Email setup","href":"/docs/en/email-setup"},{"title":"Email DNS configuration","href":"/docs/en/email-dns-configuration"},{"title":"Senders","href":"/docs/en/senders"},{"title":"BCC emails","href":"/docs/en/email-bcc"},{"title":"Transactional emails","href":"/docs/en/setup-transactional-emails"},{"title":"Create a custom email unsubscribe page","href":"/docs/en/create-custom-unsubscribe-page"}]},{"group":"Email deliverability \u0026 analytics","pages":[{"title":"Email message reports","href":"/docs/en/email-message-reports"},{"title":"Email deliverability","href":"/docs/en/email-deliverability"},{"title":"Deliverability insights by inbox provider","href":"/docs/en/email-deliverability-insights"},{"title":"Email reputation best practices","href":"/docs/en/email-reputation-best-practices"},{"title":"Email address validation","href":"/docs/en/email-address-validation"},{"title":"Email warm-up","href":"/docs/en/email-warm-up"},{"title":"Google Postmaster Tools","href":"/docs/en/google-postmaster-tools"},{"title":"Suppressions","href":"/docs/en/suppressions"},{"title":"Email troubleshooting","href":"/docs/en/email-troubleshooting"}]},{"group":"Design your emails","pages":[{"title":"Design emails with drag-and-drop","href":"/docs/en/design-emails-with-drag-and-drop"},{"title":"Design emails with HTML","href":"/docs/en/design-emails-with-html"},{"title":"Email unsubscribe links \u0026 headers","href":"/docs/en/unsubscribe-links-email-subscriptions"},{"title":"Email template forwarding","href":"/docs/en/email-template-forwarding"}]}]},{"group":"SMS \u0026 RCS","pages":[{"title":"SMS, MMS, and RCS overview","href":"/docs/en/sms-messaging"},{"title":"Rich Communication Services (RCS)","href":"/docs/en/rcs-messaging"},{"group":"SMS setup","pages":[{"title":"SMS setup","href":"/docs/en/sms-setup"},{"title":"Sender resource applications and country requirements","sidebarTitle":"Sender resource applications","href":"/docs/en/sms-registration-requirements"},{"title":"SMS opt-in and collection","href":"/docs/en/sms-opt-in-and-collection"},{"title":"SMS consent keyword management","href":"/docs/en/sms-consent-keyword-management"},{"title":"SMS keywords","href":"/docs/en/keywords"}]},{"group":"SMS messaging","pages":[{"title":"Promotional messaging","href":"/docs/en/sms-promotional-messaging"},{"title":"Transactional messaging","href":"/docs/en/sms-transactional-messaging"},{"title":"One-time passwords (OTP)","sidebarTitle":"One-time passwords","href":"/docs/en/sms-verify"},{"title":"Composing messages","href":"/docs/en/sms-composing-messages"},{"title":"SMS message reports","href":"/docs/en/sms-message-reports"}]}]},{"group":"Live Activities","pages":[{"title":"Live Activities","href":"/docs/en/live-activities"},{"title":"Live Activities analytics","href":"/docs/en/live-activities-analytics"}]},{"group":"Features","pages":[{"title":"A/B testing","href":"/docs/en/ab-testing"},{"title":"Multi-language messaging","href":"/docs/en/multi-language-messaging"},{"title":"Brand Kit","href":"/docs/en/brand-kit"},{"group":"Personalization","pages":[{"title":"Personalization","href":"/docs/en/message-personalization"},{"title":"Using Liquid syntax","href":"/docs/en/using-liquid-syntax"},{"title":"Data feeds","href":"/docs/en/data-feeds"},{"title":"Personalize with Custom Events","href":"/docs/en/personalization-custom-event"},{"title":"Personalize with properties","href":"/docs/en/personalization-properties-and-tags"},{"title":"Personalize messages with API custom_data","href":"/docs/en/personalization-api-custom-data"},{"title":"Dynamic Content with CSV","href":"/docs/en/dynamic-content"}]},{"group":"URLs, Links, \u0026 Deep Links","pages":[{"title":"URLs, links, \u0026 deep links","href":"/docs/en/links"},{"title":"Deep linking","href":"/docs/en/deep-linking"},{"title":"Email unsubscribe links \u0026 headers","href":"/docs/en/unsubscribe-links-email-subscriptions"}]},{"title":"Retargeting messages","href":"/docs/en/retargeting"},{"title":"Templates","href":"/docs/en/templates"},{"title":"Labels","href":"/docs/en/labels"}]}]},{"group":"Journeys","pages":[{"title":"Journeys overview","href":"/docs/en/journeys-overview"},{"group":"Journey features","pages":[{"title":"Journey settings","href":"/docs/en/journeys-settings"},{"title":"Journey messages","href":"/docs/en/journeys-messages"},{"title":"Journey message A/B testing","sidebarTitle":"A/B testing","tag":"BETA","href":"/docs/en/journeys-ab-testing"},{"title":"Journey actions","href":"/docs/en/journeys-actions"},{"title":"Journey webhooks","href":"/docs/en/journeys-webhook"},{"title":"Send WhatsApp Messages via Journey Webhooks","href":"/docs/en/sending-whatsapp-messages-via-journey-webhooks"},{"title":"Managing journeys","href":"/docs/en/managing-journeys"},{"title":"Journey version history","tag":"NEW","href":"/docs/en/journeys-version-history"},{"title":"Journey analytics","href":"/docs/en/journeys-analytics"}]},{"title":"Journey examples","href":"/docs/en/journeys-examples"},{"title":"Control Journey membership with tags","href":"/docs/en/journeys-membership-tags"}]},{"group":"OneSignal AI","pages":[{"title":"OneSignal AI","tag":"BETA","href":"/docs/en/onesignal-ai"},{"title":"OneSignal AI skills","sidebarTitle":"Skills","tag":"BETA","href":"/docs/en/onesignal-ai-skills"},{"title":"OneSignal Home","href":"/docs/en/onesignal-home"},{"title":"OneSignal MCP Server","href":"/docs/en/model-context-protocol"},{"title":"OneSignal AI data practices","mode":"frame","href":"/docs/en/ai-data-practices"},{"title":"AI message composer","href":"/docs/en/ai-message-composer"},{"title":"Slack agent","href":"/docs/en/slack-agent"}]},{"group":"Audience \u0026 events","pages":[{"title":"Segments","href":"/docs/en/segmentation"},{"title":"User-based segmentation","description":"User-based segments group Users with all of their Subscriptions, so one segment reaches every channel. In beta. Covers segment evaluation, optional Subscription filters for push and in-app messages, and user counts.","tag":"BETA","href":"/docs/en/user-based-segmentation"},{"group":"Users \u0026 Subscriptions","pages":[{"title":"Users","href":"/docs/en/users"},{"title":"Subscriptions","href":"/docs/en/subscriptions"},{"title":"Sessions","href":"/docs/en/sessions"},{"title":"User and Subscription Profiles","href":"/docs/en/user-subscription-profiles"},{"title":"Aliases","href":"/docs/en/aliases"},{"title":"Test users","href":"/docs/en/test-users"},{"title":"Delete users","href":"/docs/en/delete-users"}]},{"group":"Events","pages":[{"title":"Message events","href":"/docs/en/message-events"},{"title":"Session events","href":"/docs/en/session-events"},{"group":"Custom events","pages":[{"title":"Custom events","href":"/docs/en/custom-events"},{"title":"Custom event best practices","href":"/docs/en/custom-event-best-practices"},{"title":"Custom event storage and retention","href":"/docs/en/custom-event-storage"}]}]},{"group":"Tags","pages":[{"title":"Tags","href":"/docs/en/add-user-data-tags"},{"title":"Tags: Time Operators","href":"/docs/en/time-operators"}]},{"title":"Import","href":"/docs/en/import"}]},{"group":"Analytics \u0026 Integrations","pages":[{"group":"Analytics","pages":[{"title":"Analytics overview","href":"/docs/en/analytics-overview"},{"title":"Metrics glossary","href":"/docs/en/analytics-metrics-glossary"},{"title":"Goals","sidebarTitle":"Goals","tag":"BETA","href":"/docs/en/goals"},{"title":"Exporting data","href":"/docs/en/exporting-data"},{"title":"Template analytics","href":"/docs/en/template-analytics"},{"title":"Conversion metrics","href":"/docs/en/conversion-metrics"},{"title":"Engagement trends","href":"/docs/en/engagement-analytics"},{"title":"Subscription trends","href":"/docs/en/subscription-trends"},{"title":"Sessions volume","href":"/docs/en/sessions-volume"},{"group":"Retention metrics","pages":[{"title":"Retention metrics","href":"/docs/en/retention-metrics"},{"title":"Interpreting retention curves","href":"/docs/en/interpreting-retention-curves"}]},{"title":"Custom Outcomes","href":"/docs/en/custom-outcomes"}]},{"group":"Event Streams","pages":[{"title":"Event Streams","href":"/docs/en/event-streams"},{"title":"Event Stream data reference","sidebarTitle":"Event Stream data","href":"/docs/en/event-streams-data"},{"title":"In-app message event streams","href":"/docs/en/iam-event-streams"},{"title":"Google Sheets integration with Event Streams","href":"/docs/en/google-sheets-integration-with-event-streams"}]},{"group":"Integrations","pages":[{"title":"Integrations overview","href":"/docs/en/integrations"},{"title":"Data warehouse, DMP, \u0026 CRM integration","href":"/docs/en/database-dmp-crm-integration"},{"group":"OneSignal as data source","pages":[{"title":"Amplitude","href":"/docs/en/amplitude"},{"title":"Databricks","href":"/docs/en/databricks"},{"title":"Google BigQuery","href":"/docs/en/bigquery"},{"title":"Mixpanel","href":"/docs/en/mixpanel"},{"title":"Snowflake","href":"/docs/en/snowflake"},{"title":"Segment (Twilio)","href":"/docs/en/segment-onesignal-integration"}]},{"group":"OneSignal as destination","pages":[{"title":"Adobe Audience Manager","href":"/docs/en/adobe-audience-manager"},{"title":"AlloyDB","href":"/docs/en/alloydb"},{"title":"Amazon Athena","href":"/docs/en/amazon-athena"},{"title":"Amazon S3","href":"/docs/en/s3"},{"title":"Amplitude","href":"/docs/en/amplitude"},{"title":"Apache Kafka","href":"/docs/en/kafka"},{"title":"Amazon Redshift","href":"/docs/en/amazon-redshift"},{"title":"Azure Synapse","href":"/docs/en/azure-synapse"},{"title":"ClickHouse","href":"/docs/en/clickhouse"},{"title":"Confluent Cloud","href":"/docs/en/confluent-cloud"},{"title":"Databricks","href":"/docs/en/databricks"},{"title":"Elasticsearch","href":"/docs/en/elasticsearch"},{"title":"Google BigQuery","href":"/docs/en/bigquery"},{"title":"Google Cloud SQL","href":"/docs/en/google-cloud-sql"},{"title":"Google Sheets","href":"/docs/en/google-sheets"},{"title":"Greenplum","href":"/docs/en/greenplum"},{"title":"HubSpot","href":"/docs/en/hubspot"},{"title":"Materialize","href":"/docs/en/materialize"},{"title":"Microsoft Fabric","href":"/docs/en/microsoft-fabric"},{"title":"Mixpanel","href":"/docs/en/mixpanel"},{"title":"MotherDuck","href":"/docs/en/motherduck"},{"title":"MySQL","href":"/docs/en/mysql"},{"title":"PostgreSQL","href":"/docs/en/postgresql"},{"title":"Pub/Sub","href":"/docs/en/google-pubsub"},{"title":"SingleStore","href":"/docs/en/singlestore"},{"title":"Snowflake","href":"/docs/en/snowflake"},{"title":"SQL Server","href":"/docs/en/sql-server"},{"title":"Starburst Enterprise","href":"/docs/en/starburst-enterprise"},{"title":"Starburst Galaxy","href":"/docs/en/starburst-galaxy"},{"title":"Trino","href":"/docs/en/trino"},{"title":"Segment (Twilio)","href":"/docs/en/segment-onesignal-integration"}]},{"group":"Attribution","pages":[{"title":"RevenueCat","href":"/docs/en/revenuecat"},{"title":"Adjust","href":"/docs/en/adjust"},{"title":"BlueConic","href":"/docs/en/blueconic"}]},{"title":"Building an integration with OneSignal: partner guide","href":"/docs/en/building-an-integration-with-onesignal-partner-guide"}]}]},{"group":"Privacy \u0026 Security","pages":[{"group":"Security credentials","pages":[{"title":"SOC 2 Type II","href":"/docs/en/soc-2-type-ii"},{"title":"ISO 27001","href":"/docs/en/iso27001"},{"title":"HIPAA","href":"/docs/en/hipaa"}]},{"group":"Data privacy \u0026 regulatory compliance","pages":[{"title":"GDPR \u0026 Individual Rights","href":"/docs/en/gdpr-compliance"},{"title":"EU-US Data Privacy Framework","href":"/docs/en/eu-us-data-privacy-framework"},{"title":"Email regulatory compliance","href":"/docs/en/email-compliance"},{"title":"SMS regulatory compliance","href":"/docs/en/sms-regulatory-compliance"},{"title":"Apple App Privacy Requirements","href":"/docs/en/apple-app-privacy-requirements"},{"title":"Google Play Data Safety Requirements","href":"/docs/en/google-play-data-safety-requirements"},{"title":"Data collection \u0026 security FAQs","href":"/docs/en/data-questions"},{"title":"Data collected by the OneSignal SDK","href":"/docs/en/data-collected-by-the-onesignal-sdk"},{"title":"Handling personal data","href":"/docs/en/handling-personal-data"},{"title":"Data taxonomy","href":"/docs/en/data-taxonomy"},{"title":"OneSignal AI data practices","mode":"frame","href":"/docs/en/ai-data-practices"}]},{"group":"Authentication","pages":[{"title":"2-step authentication","href":"/docs/en/2-step-authentication"},{"title":"Single Sign-On (SSO)","href":"/docs/en/sso"}]}]}]},{"tab":"Developer Guides","pages":[{"title":"Developer Guides","href":"/docs/en/developers"}]},{"tab":"Tutorials","pages":[{"title":"Tutorials","href":"/docs/en/tutorials"}]},{"tab":"API Reference","pages":[{"title":"API Reference","href":"/reference/rest-api-overview"}]},{"tab":"Release Notes","pages":[{"title":"Release Notes","href":"/release-notes/changelog"}]},{"tab":"Customer Success Hub","pages":[{"title":"Customer Success Hub","href":"/docs/en/customer-success-hub"}]}],"global":{"anchors":[{"anchor":"Blog","icon":"newspaper","href":"https://onesignal.com/blog"},{"anchor":"GitHub","icon":"github","href":"https://github.com/OneSignal"},{"anchor":"YouTube","icon":"youtube","href":"https://www.youtube.com/@onesignalofficial/playlists"}]}},{"language":"cn","pages":[{"title":"cn","href":"/docs/cn/segmentation"}]},{"language":"ko","pages":[{"title":"ko","href":"/docs/ko/segmentation"}]},{"language":"ja","pages":[{"title":"ja","href":"/docs/ja/segmentation"}]},{"language":"tr","pages":[{"title":"tr","href":"/docs/tr/segmentation"}]},{"language":"pt-BR","pages":[{"title":"pt-BR","href":"/docs/pt-BR/segmentation"}]},{"language":"es","pages":[{"title":"es","href":"/docs/es/segmentation"}]},{"language":"fr","pages":[{"title":"fr","href":"/docs/fr/segmentation"}]}]},"title":"Segments - OneSignal","buildId":"dpl_2oYXwqkEXirXBPk8wV1FtM5USFWi","deploymentId":"dpl_2oYXwqkEXirXBPk8wV1FtM5USFWi","dynamics":["07c022d89b","a74be98ba7"],"chunks":["Frame-BbYRHtLl.js","DynamicMarkdown-DN96a4Ur.js","zoom-image-lightbox-D7yRe3On.js","lightbox-handle-r17bVUz3.js"]}