Creating a customer segment is similar to building a cart price rule, except that the options include customer segment-specific attributes.
Customer Segments grid
Column | Description |
---|---|
ID | The unique ID of customer segment. |
Segment | The name of customer segment. |
Status | Indicates whether the customer segment is Active or Inactive. |
Website | Indicates the website to which the customer segment belongs. |
On the Admin sidebar, go to Stores > Settings > Configuration.
In the left panel, expand Customers and choose Customer Configuration.
Expand the Customer Segments section.
Verify that Enable Customer Segment Functionality is set to Yes
.
(Optional) To disable real-time validation for customer segments, set Real-time Check if Customer is Matched by Segment to No
.
When you disable real-time validation, customer segments are validated by a single combined condition SQL query. Disabling this function improves performance of segments validation if there are many customer segments in the system. However, the validation does not work with a split database or when there are no registered customers.
When complete, click Save Config.
The following steps use an example for creating a customer segment that targets female customers in Los Angeles.
On the Admin sidebar, go to Customers > Segments.
In the upper-right corner, click Add Segment.
Enter a Segment Name that identifies the customer segment when working in the Admin.
Enter a brief Description that explains the purpose of the segment.
Set Assigned to Website to the website where the customer segment can be used.
Set the Status to Active or Inactive.
To identify the customer types that you want to use for applying the segment, set Apply to to one of the following:
Visitors and Registered Customers
- Includes all shoppers, regardless of whether they are logged in to an account.Registered Customers
- Includes only shoppers who are logged in to an account.Visitors
- Includes only shoppers who are not logged in to an account.If you are creating a segment based on customer attributes stored in a customer account, it is a best practice to apply the segment to registered customers only.
Click Save and Continue Edit.
After saving the segment General Properties, additional options become available in the left panel.
General Properties
Field | Description |
---|---|
Segment Name | A name that identifies the segment for internal reference. |
Description | A brief description that explains the purpose of the segment for internal reference. |
Assigned to Website | The single website where the segment can be used. |
Status | Activates and deactivates the segment. Any associated price rules and banners are deactivated when the segment is disabled. Options: Active / Inactive |
Apply to | Defines the customer types to which the segment is applied. The selection influences the set of conditions available for creating the segment. The setting cannot be changed after the segment is saved. |
In the left pane, click Conditions.
The default condition begins with If ALL of these conditions are TRUE: on the page.
Create a condition that targets female customers:
Click the Add icon to display the list of conditions and select Gender
.
Leave the default is condition control option.
Click … and select female
.
Create another condition that targets residents of Los Angeles:
On the next line, click the Add icon and select Customer Address
.
This action creates a parent condition where you can define one or more address fields to match.
Click the Add icon to display the list of address fields and select City
.
Click is to display the condition control options and select contains
.
Click … and enter Los Angeles
.
On the next line, click the Add icon and select State/Province
.
Leave the default is condition control option.
Click … and select United States > California
.
Click Save and Continue Edit.
In the left pane, click Matched Customers to display all customers who match the condition.
If the list of customers meets your goal, click Save to complete the customer segment.
The customer segment can now be used for targeting promotions, content, and mailings.
Matched Customers grid
Column | Description |
---|---|
ID | The customer ID of a registered customer. |
Name | The name of a registered customer. |
The email address of a registered customer. | |
Group | The customer group to which the customer is assigned. |
Phone | The phone number of the customer. |
ZIP | The ZIP or postal code of the customer. |
Country | The country where the customer is located. |
State / Province | The state or province where the customer is located. |
Customer Since | The date and time the customer account was created. |
On the Admin sidebar, go to Customers > Segments.
Find the segment to be deleted and select it.
In the menu bar, click Delete button.
To confirm the action, click OK.
Button | Description |
---|---|
Back | Returns to the Customer Segments page without saving changes. |
Delete | Deletes the current customer segment. Customers or completed orders associated with the customer in the segment are not removed. |
Reset | Resets any unsaved changes in the customer segment form to their previous values. |
Refresh Segment Data | Refreshes the segment data to the most recently saved values. Relevant if any segment data is unavailable or out of date. |
Save and Continue Edit | Saves changes and keeps the customer segment open. |
Save | Saves changes and closes the customer segment. |
Watch this video for a demonstration of creating customer segments: