Salesforce workflow automation uses configured business logic to perform tasks when CRM records change, a scheduled time arrives, or a user starts a guided process. Salesforce Flow Builder is the primary declarative tool for building new automations, including record updates, sales handoffs, task creation and service case routing. For agent-based customer operations, see our CRM AI agents guide, which covers record access and controlled updates. For an evaluation of Salesforce alongside other CRM platforms, see our comparison of CRMs with workflow automation.
For example, when an opportunity is marked Closed Won, a record-triggered flow can create an onboarding task for the appropriate account team. A well-designed flow checks the qualifying transition, avoids duplicate work and confirms the result rather than reacting indiscriminately to every edit.
Salesforce ended support for Workflow Rules and Process Builder on December 31, 2025. Existing automations can continue running, but new projects should use Flow Builder, and legacy automation should be migrated and tested deliberately. This guide describes documented functionality and an illustrative implementation, not a hands-on test in a live Salesforce organization.
What is Salesforce workflow automation?
Salesforce Flow is the product used to build, manage and run flows. Flow Builder is its visual authoring tool, and an individual flow defines a particular automation. An administrator configures its trigger, conditions, elements and data resources to implement the business requirement.
A flow might read account information, evaluate a decision, create a related record or request an authorized external action. Connectors determine the execution path between elements; resources hold values such as record fields, variables and formulas. A flow can run in the background or guide a person through an interactive process.
Native Salesforce automation is different from operating application screens with software bots. Where an older system lacks a suitable interface, Salesforce robotic process automation may handle that specific task. Use supported record operations and integrations instead of a screen-based bot when possible.
Choose the right automation tool
Start by identifying the event or interaction that should begin the workflow. A record being changed, an employee requesting an approval and a nightly maintenance run are different requirements.
| Tool or flow type | Best fit | Example |
|---|---|---|
| Record-triggered flow | Automation that starts with a record event | Create a task when an opportunity becomes Closed Won |
| Screen flow | Guided interaction that needs user input | Collect case resolution details |
| Schedule-triggered flow | Recurring checks at a configured time | Review opportunities with overdue follow-up |
| Platform event-triggered flow | Respond to a published platform event | Process an integration status notification |
| Autolaunched flow without a trigger | Reusable background logic invoked by another supported mechanism | Apply standardized record enrichment |
| Approval process | Explicit approval stages and accountable decision makers | Route a discount request for authorization |
| Apex | Specialized coded logic or complex transaction requirements | Implement a carefully designed custom service |
Before-save vs. after-save record-triggered flows
When a record-triggered flow only needs to change fields on the record that starts it, the Fast Field Updates option is usually appropriate. It runs before the record is saved and can assign values to the triggering record without a separate update operation. It is not the right choice for creating a related task.
When the automation needs to create or update other records, or perform a supported action after the triggering record is saved, choose Actions and Related Records. Be aware that after-save work may still be part of the same transaction. A separate asynchronous path can be appropriate for supported external operations, subject to the platform’s execution constraints.
Flow vs. Apex vs. AI agents
Flow is a useful starting point for predictable business rules. Apex is Salesforce’s programming language and may be more appropriate when transaction handling, performance or complex logic cannot be represented cleanly in a declarative flow. Teams should evaluate the complete automation landscape on an object before choosing one tool.
Agentforce can add AI-driven interpretation or action selection where the process requires it. That does not make routine record updates an AI problem. Keep permissions, approval decisions and financial validations deterministic whenever the rule can be specified. Our AI agents for business automation guide explains this distinction in more detail.
Practical Salesforce workflow examples
The following examples show how Salesforce automation can support sales and service operations. They are illustrative process designs; the exact objects, fields, licenses and permissions depend on your organization.
| Use case | Trigger and action | Important safeguard |
|---|---|---|
| Lead assignment | New or qualified lead; route to eligible owner and create follow-up | Respect account ownership and existing assignment rules |
| Opportunity handoff | Opportunity first enters Closed Won; create onboarding task | Ensure one handoff per agreed business event |
| Discount approval | Requested discount exceeds the approved policy threshold; initiate approval | Require an authorized approver, not a field change alone |
| Case routing | Case meets defined severity or product conditions; route to eligible team | Escalate missing or ambiguous classification |
| Renewal reminders | Contract or opportunity approaches an agreed date; create review task | Suppress obsolete reminders when dates or status change |
| Data quality | Record is created or edited; normalize selected fields | Do not overwrite authoritative information with blanks |
| External order handoff | Approved order event; request supported downstream integration | Verify the external order ID and reconcile timeouts |
Lead assignment and opportunity follow-ups are covered more broadly in our sales workflow automation guide. If leads arrive in Intercom rather than Salesforce directly, the Intercom Zapier lead sync workflow explains identity matching and deduplication across systems.
How to build a record-triggered flow
Consider a sales team that needs exactly one initial onboarding task after an opportunity is won. The flow should associate the task with the opportunity and route it to an authorized owner. Later edits must not create another onboarding task. The following configuration is an illustrative starting point; verify field names and options in a sandbox or development organization.
1. Define the business event and acceptance criteria
The triggering event is a qualifying opportunity reaching Closed Won, not simply any edit to a won opportunity. Decide whether a record created directly in Closed Won should also qualify. Define what should happen if a deal is reopened and subsequently won again: for this example, retain one initial onboarding task per opportunity unless an authorized person deliberately resets the handoff.
Identify the actual opportunity stage values in your Salesforce organization. Confirm who owns the onboarding task, what its due date should be, and which existing automations already run on the Opportunity object.
2. Create the record-triggered flow
Open Salesforce Setup, find Flows, and create a new Record-Triggered Flow. Salesforce also provides access to flows through its Automation app where available. Select Opportunity as the object and choose the create or update events required by your policy.
Configure the entry condition for the actual Closed Won stage. For updates, choose the option that runs only when the record is updated to meet the conditions, where available. Select Actions and Related Records because this flow will create a separate Task record. Confirm the start configuration against the treatment of records initially created in the qualifying stage.
3. Check whether the handoff already exists
Add a lookup for an existing handoff record or a dedicated identifier associated with the opportunity and the onboarding operation. Use a Decision element to branch between an existing handoff and a new one. If a handoff already exists, stop or reconcile the existing result according to your process policy.
A search before creation helps prevent duplicates but is not a complete concurrency guarantee. For processes requiring strong uniqueness, consider a dedicated custom handoff record with an enforced unique business key and an appropriately transactional implementation. Coordinate this design with the administrator or developer who owns the object.
4. Configure the task and failure paths
Use Create Records to create a Task on the eligible path. Map its related record to the triggering opportunity ID, its owner to a valid user or supported queue, and its subject to the agreed onboarding task label. Populate due date, status and priority using the values required by your organization.
Configure fault handling for elements that support fault paths. Record the business identifier and an actionable error without exposing confidential data to unnecessary recipients. Decide whether a failure should roll back the record transaction or create a recoverable operational exception; test the actual behavior of that design.
5. Debug, validate and activate
Save the flow with a descriptive label, API name and purpose. Use Flow Builder’s debugging capabilities where supported, then test real record changes in an isolated environment. Inspect the Task records and any handoff identifiers to confirm that the intended changes occurred.
| Test | Expected outcome |
|---|---|
| Opportunity moves to Closed Won | One onboarding task with the correct related record and owner |
| Unrelated edit on a won opportunity | No second onboarding task |
| Opportunity created as Closed Won | Follows the documented create-event policy |
| Reopened and won again | Existing initial handoff is preserved unless an approved reset applies |
| Missing or invalid task owner | Failure is surfaced and assigned for resolution |
| Bulk opportunity update | Correct results without duplicate tasks or transaction-limit failures |
Check related active automation before deploying. Activate only the approved version through your organization’s release process, monitor initial executions, and have a plan to deactivate or revert the change if incorrect tasks are being created. A rollback of the flow definition does not automatically undo previously created records.
Migrate Workflow Rules and Process Builder
Salesforce’s end-of-support guidance identifies December 31, 2025 as the retirement date for Workflow Rules and Process Builder. Existing legacy definitions may still execute, and administrators may be able to edit or activate them, but they should not be the foundation of new automation.
Use an inventory to identify active workflow rules, processes, scheduled actions, approval steps and dependencies. Salesforce provides a Migrate to Flow tool for supported migration scenarios. It is a starting point for conversion, not proof that the generated flow behaves identically.
A controlled migration approach
First, document the business purpose, entry criteria, fields changed, recipients, time-dependent behavior and related automation of each legacy definition. Remove redundant logic from the proposed design only after the process owner confirms that it is no longer required.
Next, build or convert the flow and compare outcomes in a sandbox. Pay special attention to execution order, record updates that trigger other automation, and scheduled actions that are already pending. A scheduled path in a record-triggered flow is not the same as an independent schedule-triggered flow; choose the replacement based on the original timing requirement.
Finally, plan the cutover so the old and new definitions do not both perform the same write or send the same notification. Confirm what happens to queued legacy actions before deactivating the old automation. Preserve an appropriate rollback plan and verify the new flow against the original acceptance criteria.
Test, secure and maintain Salesforce flows
The reliability of a Salesforce flow depends on the wider system of active automation, not only the appearance of its canvas. Review the Flow Trigger Explorer where applicable to understand record-triggered flows and their configured execution order. Also account for Apex triggers, validation rules, assignment logic and external integration behavior.
Prevent repeated work and excessive data operations
Use specific start conditions and stable business identifiers. Avoid placing repeated record queries or writes inside loops when collection-based processing can perform them together. Test representative bulk updates and check the current Salesforce transaction and flow limits for the actual feature and edition you use.
Check execution context and integration permissions
The identity and permission context of a flow depend on its type and configuration. Confirm whether the actual runtime can access or modify the selected records, restrict sensitive fields, and review how external connections authenticate. Keep confidential values out of diagnostic notifications. Our AI workflow automation governance guide covers additional authorization and oversight for model-assisted workflows.
Monitor business outcomes and failure recovery
Track verified outcomes such as correctly assigned leads, completed handoffs, unresolved failures, duplicate tasks and elapsed processing time. Review flow errors and investigate uncertain external writes before repeating them. Use the release and recovery principles in our workflow automation best practices guide when maintaining production automations.
Before expanding automation, confirm the plan’s available features, required entitlements, integration costs and ongoing administrative work. Do not assume that a Salesforce subscription includes every orchestration capability or that automation will eliminate manual work in all cases.
Frequently asked questions
Is Salesforce Flow the same as Workflow Rules?
No. Workflow Rules are a legacy feature for criteria-based actions. Flow Builder supports a broader visual automation model with different triggers, branching, record operations and interactive experiences. Salesforce ended support for Workflow Rules and Process Builder on December 31, 2025.
Can Salesforce automation run without code?
Yes. Many record updates, task assignments, guided forms and other workflows can be configured in Flow Builder. Complex requirements may still benefit from Apex or a dedicated integration.
Which Salesforce flow should I use to create a follow-up task?
For a task triggered by an eligible record creation or update, use a record-triggered flow configured for Actions and Related Records. Define the exact event and duplicate-prevention behavior.
Can a Salesforce flow connect to other applications?
Yes, through supported integration mechanisms, including configured external services or connectors where available. Verify authentication, permissions, execution context and the actual downstream result.
Does Salesforce workflow automation require Agentforce?
No. Salesforce Flow can automate deterministic business logic without an AI agent. Consider AI only where interpretation or reasoning provides measurable additional value.

