Understanding Groups: Role, Segmentation, and Use in Flows

Contact groups help you segment and manage audiences in RapidPro. A group can act like a label you apply manually, or a dynamic “Smart Group” that updates automatically based on a search query. Groups are commonly used to trigger flows and campaigns, build broadcast audiences, and track who is eligible for a program. Because contacts can belong to multiple groups—and membership can change over time—groups are a flexible way to organize contacts without changing their core profile data.

Groups are commonly used to trigger flows and campaigns, build broadcast audiences, and track eligibility over time. Because contacts can belong to multiple groups, group membership is a flexible way to organize contacts without changing their core profile data.

Quick setup checklist

Use this checklist to understand groups, create one, and start using groups in flows and segmentation.

  1. Review how groups work (manual vs dynamic membership)
  2. Create a new contact group from Contacts
  3. Add or remove contacts from groups in flows
  4. Reference group membership using @contact.groups
  5. Apply groups to common segmentation and campaign use cases
1
Understand how contact groups work

Contact groups act as labels or containers that help you organize contacts for messaging and automation. Depending on how they are created and maintained, membership can be:

  • Manual (you add/remove contacts yourself or via flows)
  • Dynamic (Smart Groups update automatically based on a search query)

Key characteristics

  • Contacts can be added to or removed from groups over time
  • Groups can be used for flows, campaigns, and broadcasts
  • A contact can belong to multiple groups at once

[CAPTURE 1: Contacts page showing groups list]

2
Create a contact group

You can create contact groups from the Contacts section. Once created, you can start adding contacts manually or via flows.

[CAPTURE 2: Create new contact group interface]

For the full step-by-step guide, see: Creating a Group: Manual Procedure via the Contacts Tab.

3
Use groups in flows (add/remove contacts automatically)

In a flow, you can update group membership automatically using group actions. This is useful for tracking progress and segmenting contacts based on responses.

Common group actions

  • Add contact to a group
  • Remove contact from a group

Typical reasons to use group actions

  • Track who completed a step or program
  • Segment contacts based on answers (e.g., eligibility, interests, location)
  • Control who should receive future broadcasts or campaigns

[CAPTURE 3: Flow editor with Add/Remove group actions]

4
Reference group membership in flow logic

You can reference a contact’s current group memberships using:
@contact.groups

This variable returns a list of all groups the contact currently belongs to, and it can be used in:

  • Message text
  • Conditions and expressions
  • Split logic and routing

[CAPTURE 4: Flow expression referencing @contact.groups]

5
Apply groups to common segmentation and campaign use cases

Contact groups are commonly used to:

  • Identify contacts who completed a flow (completion tracking)
  • Track opt-ins or opt-outs (subscription management)
  • Control campaign eligibility (only contacts in a specific group receive campaign events)
  • Segment contacts by status, role, or behavior

If you need groups that stay updated automatically based on criteria, consider using Smart Groups created from a contact search query.

Common issues

A contact is not in the expected group

Possible causes

  • The flow action was not reached
  • The group action was misconfigured

Fix

Verify that the contact passes through the “Add contact to a group” action in the flow.

A contact appears in multiple groups

Explanation

Contacts can belong to multiple groups at the same time.

Fix

Remove the contact from any groups that should no longer apply.

@contact.groups is empty

Possible cause

The contact does not currently belong to any groups.

Fix

Ensure the contact has been added to at least one group (manually or via a flow action).