Branch, filter, loop and transform in workflows
Make decisions and repeat work in a Softr workflow: branch on a condition, filter a run, loop over a list of items, and transform data between your steps.
Workflows can make decisions and repeat work. A branch picks a path. A filter stops the run when a condition fails. A loop repeats steps for each item in a list. A transform reshapes data between steps.
To use data from earlier steps in these settings, see Map data between steps.
Branch
The Branches step splits the run into several paths, named A, B, C and so on. Each path starts with its own condition. Every path whose condition is met runs, at the same time as the others. A path whose condition is not met stops there.
- Add a Branches step.
- Select a path on the canvas, then set its condition, such as category is Billing.
- Select Add in the Branches settings to add another path.


For example, after an AI step sorts a request, send billing requests to Slack, assign technical ones to support, and email the sales lead about the others.
If no condition is met, no path runs. To handle every other case, add a path with the opposite condition. Paths don’t join again: if two paths need the same step, add it to each path.
Combine branches with AI steps to route a run on an AI result. See Route a run with AI.
Filter
The Filter action checks a condition and stops the workflow if the condition is not met. Use it when nothing needs to happen in the “no” case.
For example, a workflow triggers on every new record of a table. Add a Filter at the start that stops the run when the record’s “Status” is not “Ready”. Only “Ready” records continue.
Unlike Branches, Filter doesn’t create paths. It stops the run early. Each path of a Branches step starts with a filter like this one.
Loop
The Bulk actions (Loop) step runs a group of steps once for each item in a list. It needs a Basic plan or higher.
To set up a loop:
- Under List to run actions for, pick a list of items, such as the records a Find multiple records step returns.
- Add the actions that run once per item inside the loop.
- Inside the loop, pick the current item’s fields under the loop step in the variable picker.
After the last item, the workflow continues with the next action after the loop.

For example, find all “Pending” orders, then loop over them and email each customer a status update.
When items fail
A step inside the loop can fail for one item, for example when the item has no record ID. The loop then goes on with the next item.
- If at least one item runs without a failure, the loop succeeds and the workflow continues after it. The
failedIterationsoutput of the loop tells you how many items failed. - If every item fails, the loop fails with the message
Every iteration of the loop failed (3 of 3). Last error: .... The workflow stops after the loop, and the run counts as failed. You get the failure email, and after 5 failed runs in a row the workflow turns off. - To let the workflow go on after a loop where every item failed, turn on Continue on error in the loop settings.
A failure that a path of the failed step handles, such as Continue on error on that step, does not count as a failed item.
When you test the loop in the builder, the test follows the same rule for the items it runs.
Nested loops
Place a Loop inside another Loop when each item of the outer list contains its own list.
For example, you have a list of tasks, and each task has several tags. You want one record per task and tag combination.
Loop Tasks
└── Loop Tags of this Task
└── Create record (Task + Tag)
└── Mark Task as checkedIf a task has 3 tags, the inner loop runs 3 times and creates 3 records for that task. The outer loop then moves on to the next task. You can nest more than two levels.
A loop runs at most 500 times per run. In a test run, it runs 5 times.
Transform data
The Transform data action creates new values with formulas, the same syntax as the formula fields of Softr Databases. See Formula reference. Use it to reshape, calculate or extract data between steps.
For example:
- Increment a counter:
{vote_count} + 1. - Get the day of the week from a date:
WEEKDAY({submission_date}). - Return different values for a condition:
IF().
You name each output field yourself, and select Add field to add another. The names become variables in later steps. Select Help me write a formula to let AI write the formula from a description.

Transform data or run custom code
| Transform data | Run custom code | |
|---|---|---|
| Best for | Simple calculations, text formatting, date operations | Complex logic, JSON parsing, multi-step transformations |
| Syntax | Softr formula language | JavaScript or Python |
| Setup | Write a formula | Define input variables, write code |
| Plan | All plans | Pro plan and higher |
For example, an “Upvote” button starts a workflow. Find the record to read its vote_count, use Transform data with {vote_count} + 1, then update the record with the new value.
For logic that these steps cannot express, write it in JavaScript or Python with Run custom code.