# Understanding workflow conditions
_Ke5Vndsp.jpg)
## What are the conditions
A condition checks whether certain criteria are met before the workflow continues. Based on the result, the workflow can follow different paths or decide whether to run specific actions.
A workflow can have multiple conditions that determine which path to follow.
## Types of conditions
| Condition | Evaluates | Available options | Configuration |
| --- | --- | --- | --- |
| An event occurred
(Event-based) | Has a specific event happened? | • Email opened
• Email clicked
• Customer unsubscribed
• Customer purchased | • Event type
• Time email selection (optional) |
| Customer criteria
(Data comparison) | Does customer data match criteria? | • 8 customer fields with flexible operators | • Field selector
• Operator
• Compare value
• AND/OR logic |
_D0Ef5sdV.jpg)
* **Event:** Select the event you want to check for.
* **Email:** Choose the specific email associated with the event, or leave it as **Any email** to check whether the event occurred for any customer.
*Examples:*
**Trigger:** New customer sign-up
**→ Action:** Send email (Send promotional email with CTA links)
**→ Action:** Wait (Wait for email delivery and potential click)
**→ Condition:** An event occurred - **Email clicked** (Check if customer clicked email link)
**→ Action (If True):** Add customer tags (Tag customer as `engaged`)\
\
*Suggested reading:* [Tag engaged customers after email click](https://docs.foxecom.com/xflow-app/workflows/get-started-with-workflow-templates-library/tag-engaged-customers-after-email-click)
📝 Learn more: [Workflow condition: An event occurred](https://docs.foxecom.com/xflow-app/workflows/understanding-workflow-conditions/workflow-condition-an-event-occurred)
_GukLPbsA.jpg)
* **Select variable:** Choose the customer attribute you want to evaluate.
* **Operator:** Pick the comparison rule (Equal to, Not equal to, Greater than, Less than, Greater than or equal to, Less than or equal to).
* **Compare value:** Enter the value you want to compare against the selected variable.
* **AND / OR:** Combine multiple criteria to create more advanced conditions—use **AND** when all conditions must be true, or **OR** when any single condition can trigger the branch.
* **Add criteria:** Click *Add criteria* to include additional conditions as needed.
*Examples:*
**Trigger:** New customer sign up
**→ Condition:** Customer criteria - **Order count > Greater than or equal to > 1**
**→ Action (If True):** Add customer tags (automatically adds the "loyalty member" tag to the customer's profile)
**→ Action:** Send email (sends a loyalty program welcome email to the customer)\
\
*Suggested reading*: [Loyalty program enrollment](https://docs.foxecom.com/xflow-app/workflows/get-started-with-workflow-templates-library/loyalty-program-enrollment)
📝 Learn more: [Workflow condition: Customer criteria](https://docs.foxecom.com/xflow-app/workflows/understanding-workflow-conditions/workflow-condition-customer-criteria)
### Get to know each condition type in more detail
## Order of conditions
Conditions are checked one by one, in the order they appear in the workflow. The system starts from the top and moves down step by step.
You can build workflows with multiple conditions, where each condition can lead to a different action.
**Trigger:** New customer sign up\
**→ Condition:** Customer criteria (Check if subscriber has past orders)
\
If **True**
→ **Action:** Create discount code (Create exclusive VIP discount code)
→ **Action:** Send email (Send VIP welcome email with discount)\
\
If **False** \
→ **Action:** Send email (Send standard welcome email)
→ **Condition:** An event occurred – **Email clicked** (Check if customer clicked a link in the welcome email)
→ **Action (If True):** Add customer tags (Tag customer as **engaged**)\
\
Conditions are evaluated one by one, in the order they appear in the workflow. Each True or False branch can trigger different actions or lead to another condition.
_ZOEnf50g.jpg)
## How conditions work
A workflow reaches a condition step.
The condition evaluates data from the trigger or previous actions.
If the condition is met, the workflow continues along the **Yes** path.
If the condition is not met, the workflow follows the **No** path or stops, depending on your setup.
Want a full picture? Learn more about how workflows work: [How workflows work](https://docs.foxecom.com/xflow-app/workflows/how-workflows-work)
## Related articles
Available triggers, actions, and conditions
Create a workflow
Assign a workflow to your campaign