Hello Everyone in this post let’s understand how to send email using salesforce flow through using email alert and send email core action.
If you are not followed our previous blog post feel free to check it out. Salesforce Lightning Tutorial For Beginners.
Table of Contents
Objectives
After reading this blog, you will know how to write and send an email using Salesforce Flow.
Business Use Case
Send an email to the Opportunity owner when an opportunity is closed won. The email should include Opportunity details.
Two Ways to Send Email
- Send Email Using Email Alert.
- Send Email Using Core Action.
Read the best salesforce Books: Click Here.
Send Email Using Salesforce Flow
1. Send Email Using Email Alert
If you want to send emails using email alerts then you need to create an email template and email alerts in salesforce. You can create an email template using either the Lightning Email Template or the Classic Email Template in Salesforce. Here we have created a Classic Email Template.
![Classic Email Template](https://viewonreview.com/wp-content/uploads/2022/01/Create-Email-Template.png)
Once the email template is created, then create an email alert.
![](https://viewonreview.com/wp-content/uploads/2022/01/Create-Email-Alert.png)
Next, create a record-triggered flow, then use the send email alert action.
![](https://viewonreview.com/wp-content/uploads/2022/01/Object-Configuration.png)
![](https://viewonreview.com/wp-content/uploads/2022/01/Action-Related.png)
![](https://viewonreview.com/wp-content/uploads/2022/01/Search-Email-Alert-Element.png)
Once you choose “Send Email Alert,” you’ll see a list of available email alerts. If you don’t see any, make sure you’ve configured the email alert with the correct object.
![](https://viewonreview.com/wp-content/uploads/2022/01/Available-Email-Alert.png)
Next, in add a Label and input values for the selected action add record Id.
![](https://viewonreview.com/wp-content/uploads/2022/01/Send-Email-Using-Alert.png)
Now you are done with the flow. Here is what the final flow looks like.
![](https://viewonreview.com/wp-content/uploads/2022/01/Send-Email-Using-Email-Alert.png)
2. Send Email Using Core Action.
Here let’s explore how to use email core action to send an email in salesforce flow. Here we will have the same entry criteria as above.
![](https://viewonreview.com/wp-content/uploads/2022/01/Object-Configuration.png)
![](https://viewonreview.com/wp-content/uploads/2022/01/Action-Related.png)
Next, let’s create a text template for the email body. Click New Resource to create.
![](https://viewonreview.com/wp-content/uploads/2022/01/Email-Body.png)
Once created let’s add the action element into flow.
![](https://viewonreview.com/wp-content/uploads/2022/01/Action-Element.png)
Next search send email action and select it.
![](https://viewonreview.com/wp-content/uploads/2022/01/Send-Email-Action.png)
Next, add a label. Then choose the variable created as an email body.
![](https://viewonreview.com/wp-content/uploads/2022/01/Add-Email-Body.png)
Since I need to send an email to the opportunity owner, I selected the recipient address as the opportunity owner’s email.
![](https://viewonreview.com/wp-content/uploads/2022/01/Email-Action-Configuration.png)
Note: If you don’t set the Rich Text formatted body to true, you’ll receive the email with HTML tags included.
Now we are done with our flow. Save it and test it out,
![](https://viewonreview.com/wp-content/uploads/2022/01/Send-Email-Using-Action.png)
Output
Here is the email I have received, once opportunity is closed won.
![](https://viewonreview.com/wp-content/uploads/2022/01/Send-Email-Output.png)
Conclusion
In this blog post, I’ve shown how to send an email using the Email Alert and Send Email core action in Salesforce. If you have any questions, feel free to comment.
Winter 25 Update
![](https://viewonreview.com/wp-content/uploads/2024/08/image-1-1024x851.png)
In this post, we saw how we can send email using 2 different methods using flow. Also, we saw what has changed in Summer 23 related to core email action.
Related Quick Links
- Read the best salesforce Books: Click Here.
- HTTP Callout in Salesforce Flow Without Code [GET & POST]
- How to Invoke a Flow from a Lightning Web Component
- How to update child records using salesforce flow
- How to Assign records to Queue using Salesforce Flow?
- How to create a Data Table in Salesforce Flow : Complete Guide.
- How to retrieve record Type Id in flow
- How to navigate record detail page in flow
- How to send email using flow in salesforce
- How to Display Icon In Lightning Datatable
- How to Create Record in lightning Component
- How to Delete Multiple Records Using Checkbox In Lightning Component.
Good one…!
Nice post 🤩
Thank You.
Now I want to schedule it after one day like email is sent after one day of previous days all opportunities.
Hi Kinjal,
If you want schedule a email then please have look to this blog post.
Schedule Triggered Flow in Salesforce
I know this is an older post, but just to be clear if i want to send an email template to a customer they customer must exist as a Lead, Contact or Person account. I cannot use an email field?
HI Yor Yang,
You are saying you want to send email to external customer which is not available in salesforce?
If yes, just go to help article https://help.salesforce.com/s/articleView?id=000392564&type=1.
Let me know if this is not the case.