Flow & Save Order Interaction
Diagnostic Symptoms
- Multiple automations fire on the same object and you need to predict
outcome.
- A value is being read stale, or a flow appears to run twice.
- Deciding whether to put logic in a before-save Flow vs a before
trigger vs an after-save Flow.
- Diagnosing a recursion loop crossing triggers and flows.
Out of Scope
- Plain CRUD with a single automation — there is nothing to order.
- Platform-event-triggered or schedule-triggered flows — they are not
part of the DML save order.
The Save Order (canonical, 20 steps)
Numbering matches the Apex Developer Guide, Triggers and Order of Execution. Use these numbers verbatim — several superseded 16-, 18-, and 19-step numberings are still in wide circulation and do not line up.
- Load the original record from the database (or initialize it for an upsert).
- Overwrite with the new field values from the request; run request-type system validation.
- Before-save Flows (record-triggered, "Fast Field Updates").
- Before triggers.
- System validation re-run (required / field type / max length) and custom validation rules.
- Duplicate rules (a block action stops the save here).
- DML save (record not committed yet).
- After triggers.
- Assignment rules (Lead / Case only).
- Auto-response rules (Lead / Case only).
- Workflow rules. A workflow field update re-runs system validations and before update / after update triggers one more time, and only one more time.
- Escalation rules (Case only).
- Process Builder and workflow-launched Flows — not in a guaranteed order.
- After-save Flows (record-triggered).
- Entitlement rules.
- Roll-up summary on the parent; the parent then goes through its own save procedure.
- Roll-up summary on the grandparent.
- Criteria-based sharing evaluation.
- Commit.
- Post-commit logic (email,
@future / Queueable / Batch, asynchronous Flow paths).
A recursive save runs a truncated list. From the Note box above the list: "During a recursive save, Salesforce skips steps 9 (assignment rules) through 17 (roll-up summary field in the grandparent record)." A recursive save is a save that begins inside another save — the parent save the platform launches at step 16 ("Parent record goes through save procedure") is the documented case. Steps 1–8 and 18–20 still run; assignment, auto-response, workflow, escalation, after-save Flows (14), entitlement rules and roll-ups do not.
Before-save Flow vs before trigger is determinate. Step 3 and step 4 are separate, consecutive steps. The Flow always runs first; the trigger always runs second. If both write the same field, the trigger's value is what saves — every time, in every org. Older guidance that puts both at "step 3" and calls the outcome indeterminate is describing a superseded version of the docs page.
Decision: Before-Save Flow vs Before Trigger
- Before-save Flow — same-record field updates with no DML, no SOQL
in the hot path. Cheapest option.
- Before trigger — when you need SOQL, related-record lookup, or
complex control flow.
- After-save Flow — cross-record DML, external calls, creating
related records.
Recommended Workflow
- List every automation on the object (flows, triggers, validation,
duplicate rules, assignment, workflow).
- Pin each one to its save-order slot.
- Verify data each stage actually needs. Before-save flows cannot see
rolled-up or after-trigger-computed values.
- For recursion suspicion, trace the save chain: which automation
re-issues DML on the same record in the same transaction?
- Add a recursion guard or move the logic earlier to prevent the loop.
- Validate using Flow Debug Log + Apex Debug Log in the same
transaction.
- Document the ordering decision in the flow's description so future
admins see intent.
Official Sources Used
1---2name: flow-record-save-order-interaction3description: "Reason about how record-triggered flows interleave with the Salesforce Save Order (validation, before-save flows, before triggers, duplicate rules, after-save flows, workflow, after triggers, assignment, auto-response, escalation). Trigger keywords: save order, before-save flow, after-save flow, dml order, trigger vs flow order. NOT for choosing before-save vs after-save for one flow — use flow/record-triggered-flow-patterns. NOT for picking which tool stamps a field on save — use admin/workflow-field-update-patterns."4category: flow5salesforce-version: "Spring '25+"6well-architected-pillars:7 - Reliability8 - Operational Excellence9triggers:10 - save order11 - before-save flow12 - after-save flow13 - dml execution order14 - trigger flow interaction15tags:16 - flow17 - save-order18 - record-triggered19 - triggers20 - automation-ordering21inputs:22 - Object with multiple automations firing on insert/update23 - Suspected ordering issue (recursion, stale value, double-save)24outputs:25 - Save-order trace26 - Recommendation (move earlier, collapse, or relocate logic)27 - Recursion-guard plan28dependencies:29 - flow/record-triggered-flow-patterns30 - flow/flow-migration-from-trigger31version: 1.0.032author: Pranav Nagrecha33updated: 2026-04-2334metadata:35 source: https://skillmd.com/skills/pranavnagrecha/flow-record-save-order-interaction36---3738# Flow & Save Order Interaction3940## Diagnostic Symptoms4142- Multiple automations fire on the same object and you need to predict43 outcome.44- A value is being read stale, or a flow appears to run twice.45- Deciding whether to put logic in a before-save Flow vs a before46 trigger vs an after-save Flow.47- Diagnosing a recursion loop crossing triggers and flows.4849## Out of Scope5051- Plain CRUD with a single automation — there is nothing to order.52- Platform-event-triggered or schedule-triggered flows — they are not53 part of the DML save order.5455## The Save Order (canonical, 20 steps)5657Numbering matches the Apex Developer Guide, *Triggers and Order of Execution*. Use these numbers verbatim — several superseded 16-, 18-, and 19-step numberings are still in wide circulation and do not line up.58591. Load the original record from the database (or initialize it for an upsert).602. Overwrite with the new field values from the request; run request-type system validation.613. **Before-save Flows** (record-triggered, "Fast Field Updates").624. **Before triggers.**635. System validation re-run (required / field type / max length) **and** custom validation rules.646. Duplicate rules (a block action stops the save here).657. DML save (record not committed yet).668. After triggers.679. Assignment rules (Lead / Case only).6810. Auto-response rules (Lead / Case only).6911. Workflow rules. A workflow **field update** re-runs system validations and before update / after update triggers one more time, and only one more time.7012. Escalation rules (Case only).7113. Process Builder and workflow-launched Flows — not in a guaranteed order.7214. **After-save Flows** (record-triggered).7315. Entitlement rules.7416. Roll-up summary on the parent; the parent then goes through its own save procedure.7517. Roll-up summary on the grandparent.7618. Criteria-based sharing evaluation.7719. Commit.7820. Post-commit logic (email, `@future` / Queueable / Batch, asynchronous Flow paths).7980**A recursive save runs a truncated list.** From the Note box above the list: "During a recursive save, Salesforce skips steps 9 (assignment rules) through 17 (roll-up summary field in the grandparent record)." A recursive save is a save that begins inside another save — the parent save the platform launches at step 16 ("Parent record goes through save procedure") is the documented case. Steps 1–8 and 18–20 still run; assignment, auto-response, workflow, escalation, **after-save Flows (14)**, entitlement rules and roll-ups do not.8182**Before-save Flow vs before trigger is determinate.** Step 3 and step 4 are separate, consecutive steps. The Flow always runs first; the trigger always runs second. If both write the same field, the trigger's value is what saves — every time, in every org. Older guidance that puts both at "step 3" and calls the outcome indeterminate is describing a superseded version of the docs page.8384## Decision: Before-Save Flow vs Before Trigger8586- **Before-save Flow** — same-record field updates with no DML, no SOQL87 in the hot path. Cheapest option.88- **Before trigger** — when you need SOQL, related-record lookup, or89 complex control flow.90- **After-save Flow** — cross-record DML, external calls, creating91 related records.9293## Recommended Workflow94951. List every automation on the object (flows, triggers, validation,96 duplicate rules, assignment, workflow).972. Pin each one to its save-order slot.983. Verify data each stage actually needs. Before-save flows cannot see99 rolled-up or after-trigger-computed values.1004. For recursion suspicion, trace the save chain: which automation101 re-issues DML on the same record in the same transaction?1025. Add a recursion guard or move the logic earlier to prevent the loop.1036. Validate using Flow Debug Log + Apex Debug Log in the same104 transaction.1057. Document the ordering decision in the flow's description so future106 admins see intent.107108## Official Sources Used109110- Triggers and Order of Execution (20-step list; before-save Flows step 3, before111 triggers step 4; recursive save skips steps 9–17) —112 https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_triggers_order_of_execution.htm113- Metadata API Developer Guide — Flow (`triggerOrder`, API 54.0+) —114 https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_visual_workflow.htm115- Before-Save Flows —116 https://help.salesforce.com/s/articleView?id=sf.flow_concepts_trigger_before_save.htm