# How timing affects your workflows

Timing plays a critical role in how your workflows behave. Understanding how Wait action work, especially in relation to conditions, helps you control *when* actions happen and *which* customers receive them.

## Time between steps

Wait action in a workflow are **cumulative**. Each wait action adds to the total duration before the next step is executed.

{% hint style="info" %}

### Examples

After a product is back in stock, you may want to follow up with customers over several days:

1. Trigger: **Product Restock**
2. Send **Back-in-Stock Email**
3. Add a **Wait action: 24 hours**
4. Send **Follow-up Email**
5. Add another **Wait action: 3 days**
6. Send a **Second Follow-up Email** to encourage purchase

{% endhint %}

In this case:

* First delay: **1 day**
* Second delay: **3 days**
* **Total time before the last email: 4 days**

Each wait action extends the workflow's overall timeline.

<figure><img src="/files/RK9EwjoKxBDtvdo1ei7t" alt=""><figcaption></figcaption></figure>

## Wait action with conditions

Conditions split customers into two branches: **True** and **False**. A key thing to understand is that **conditions are evaluated at a specific point in time** (point-in-time evaluation).

Suppose you have a condition:

{% hint style="info" %}
**Order count = 0 (over all time)**

* **True** → Customer has never purchased
* **False** → Customer has purchased before
  {% endhint %}

While a customer is in the workflow, they can place an order at *any time*. So the moment when the condition is evaluated determines which branch they enter.

{% hint style="success" %}
If you add a Wait action before a condition, customers will wait until the delay is over **before the condition is checked**.
{% endhint %}

### Why place a Wait action *before* a condition?

Conditions can evaluate:

* [Workflow condition: An event occurred](/xflow-app/workflows/understanding-workflow-conditions/workflow-condition-an-event-occurred.md)
* [Workflow condition: Customer criteria](/xflow-app/workflows/understanding-workflow-conditions/workflow-condition-customer-criteria.md)

{% hint style="success" %}
If your condition depends on a customer action, you should give them **enough time to perform that action** before checking the condition.<br>

Adding a Wait action before the condition ensures the evaluation happens at the right moment.
{% endhint %}

### Best practices when using the Wait action

If you plan to send emails in **both the True and False branches**, we generally recommend:

* ✅ Send the email immediately after the condition
* ❌ Do not add a Wait action right after the condition

**Why?**

Once a condition is evaluated, the customer is assigned to a branch based on their status *at that moment*.

{% hint style="warning" %}
If you add a **Wait action after the condition**, the **customer’s data may change during the wait period**, meaning they might no longer meet the criteria of the branch they are in.
{% endhint %}

Sending the message immediately ensures:

* The message matches the customer’s current status
* The workflow logic remains accurate and predictable

***

#### 📩 **Need help?**

We’re here to make your XFlow experience smooth and successful.\
Our support team is always ready to assist you—no matter how big or small your question is.

<a href="https://admin.shopify.com/apps/xflow?chat=true&#x26;utm_source=foxecom&#x26;utm_medium=help_center_xflow_how_timing_affects_your_workflows&#x26;utm_campaign=cta_button&#x26;utm_term=chat_now" class="button primary" data-icon="comment-lines">Chat now</a> <a href="mailto:contact@help.xflow.so" class="button secondary" data-icon="envelopes">Message us</a>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.foxecom.com/xflow-app/workflows/workflows-faqs/how-timing-affects-your-workflows.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
