Segments

Documents / Data Vista

A segment is a slice of people — in everyday language, a group cut from a larger crowd (new visitors, mobile users, people who arrived from a paid campaign). In CROForge, a segment is a named audience definition: a list of conditions on attributes. An experiment attaches one segment as its Audience. If every condition passes, the visitor may enter the test (after domain allowlist and URL targeting also pass). If any condition fails, Smart Code skips the experiment for that visitor.

Words used on this page

WordEveryday meaningMeaning in CROForge
SegmentA slice or group (a market segment, a slice of pie).A named list of attribute conditions. Campaigns pick one segment on the Audience tab.
AttributeA characteristic.The field a condition compares (device type, visitor type, UTM source, page URL, and so on).
Condition AND logicAND means every rule must be true together.All conditions on a segment must pass. There is no OR between conditions. Within a text list, any listed value may match.
All TrafficEveryone who arrives, with no extra filter.The built-in default segment: name “All Traffic,” empty segmentConditions, description “Include all visitors in the test with no segment filtering.”
Standard vs CustomShipped vs homemade.Standard examples: Mobile Traffic, Desktop Traffic, New Visitors. Custom examples: “UTM Google or LinkedIn + homepage.”
visitorTypeFirst-time guest vs someone who has been here before.Attribute values NEW and RETURNING. New Visitors typically requires visitorType = NEW.
deviceTypePhone, computer, or tablet.Attribute values desktop / mobile / tablet. Exact-match conditions must use the same casing Smart Code emits.
UTMMarketing tags on a link: source, medium, campaign, term.Attributes utmSource, utmMedium, utmCampaign, utmTerm. Combine carefully — an empty UTM should not silently pass a “must be in this list” rule.
PAGE_URLThe address of the current page.URL-typed attribute. Conditions use include/exclude URL rule packs, not a single plain string.
Data VistaA view of your data library.Where you create and edit segments (Data Vista → Segments) before attaching them to experiments.
apiNameStable machine name.Conditions target an attribute (or its apiName). Use the identifier Smart Code and Data Vista share, not a free-typed nickname.

Screenshot filename: segments-list.png. Paste this page into the WordPress Code editor, then insert that screenshot from the Media library. Do not use a Markdown image tag.


What a segment is for

URL targeting answers where an experiment may run. A segment answers who may enter after those page rules pass. You build the segment once in Data Vista, then reuse it on many campaigns (desktop-only tests, new-visitor onboarding, paid-social landings).

Categories

  • Standard — system-defined. Typical examples: Mobile Traffic, Desktop Traffic, New Visitors. Also the implicit All Traffic choice on experiments (no extra filtering).
  • Custom — workspace-defined. Example: “UTM source is Google or LinkedIn AND homepage URL rules.”

The Segments screen groups the left list into Standard and Custom, with a details panel on the right. Create and edit use a modal; delete asks for confirmation.

Conditions

Each condition typically includes:

  • Attribute (or its apiName)
  • Data type (Text, Number, Boolean, or URL — inherited from the attribute)
  • Match type (exact, contains, between, URL match, and so on)
  • Expected value(s), or a URL include/exclude rule list

All conditions in a segment are evaluated as AND: the visitor must satisfy every condition. Empty conditions (All Traffic / “All”) match everyone.

Text conditions often accept a JSON array of strings and match if any item matches (OR inside that one list). That is not OR between two separate conditions. “Device is mobile AND UTM source is google” still requires both rows to pass.

Examples

SegmentConditions
All TrafficNo conditions — everyone who already passed domain and URL targeting
Desktop TrafficdeviceType exact in ["DESKTOP"] (confirm casing against Smart Code; it may emit desktop)
Mobile + TabletdeviceType in ["MOBILE","TABLET"]
New VisitorsvisitorType = NEW
Paid social landingUTM source in a list AND PAGE_URL include/exclude rules

Casing warning: attribute values produced by Smart Code must match the segment’s expected values. desktop is not DESKTOP. Exact-match operators are case sensitive. Align product conventions carefully before you launch, or the segment will match nobody.

Using a segment on an experiment

  1. Create or pick the segment under Data Vista → Segments (or keep All Traffic).
  2. Open the experiment → Audience.
  3. Select the segment and save.

Runtime order

Smart Code does not evaluate the segment in isolation. Typical live order:

  1. Domain allowlist
  2. URL targeting (experiment pages)
  3. Segment conditions (attributes)
  4. Variation assignment

If the segment does not match, the experiment is skipped for that visitor. Prefer reusable standard segments for common device filters. Document why you chose a segment in the experiment title or description so later editors do not “simplify” it to All Traffic by accident.


Related reading