Salesforce push notifications are a great way to provide real-time information to users. You can leverage push notifications in Salesforce to alert sales managers about changes to their opportunities, or service agents for cases that need immediate attention, and more!
You can send notifications for any object based on the criteria you set up to trigger the Salesforce Flow automation. This feature is available for both desktop and mobile apps. Keep reading for a walkthrough on how to set it up!
Step 1: Create the Custom Notification Type
The purpose of this step is to create a notification that will either go to the mobile or desktop app, or both. Let’s make a start!
1. Go to Setup → Notification Builder → Custom Notifications
2. Click New and give the CustomNotification a name.
This is important if you decide to have more than one type available, and I recommend making the name specific enough.
3. Select the SupportedChannels.
As you create more custom notifications, you will be able to view the channel the notification is intended for directly in the list, with the possibility to come back and edit it later.
Bear in mind that for mobile notifications, some restrictions apply. This includes (but is not limited to):
The user installing the app on their phone.
The application having notifications turned on.
The user actually looking at the app.
In some cases, if the user is both the person causing and receiving the notification, and “Mobile” and “Desktop” are selected, the user will only see the notification on the mobile device when entering the app itself, assuming they haven’t already clicked on it in the desktop app.
Step 2: Create the Flow
This is the step to actually trigger the notification to go out using Salesforce Flow. While notifications can still be sent out using Process Builder, remember this will no longer be an option considering the retirement of Process Builder scheduled for later this year.
Note: The tutorials we showcase are built-in developer edition orgs with limited data and only a few custom automations. Ensure you evaluate your existing processes properly before building new ones, including both declarative automation and custom Apex. For Flow specifically, consider the recommended practices when it comes to the number of record-triggered flows per object.
Check out the step-by-step tutorial below on how to set up a basic flow to notify Opportunity Team Members when an Opportunity is Closed.
You can take a look here at the official documentation pertaining to this core action, including all the information you have to fill in, such as the “Recipient ID”. We will be using the OpportunityId stored in a collection variable for, since this is the supported input for this parameter to trigger the notification being sent out to active Opportunity Team members.
In Setup, navigate to the Flows page, click the New button, and let’s get started!
Step 3: Testing
Now it’s time to test this lovely new feature!
For testing, you can use both the “Debug” option in flow, as well as actually trigger the notification on a test record. The place where you will look out for the notification depends on your set Notification Type (Mobile or Desktop).
As you noticed in the video, you will see a “1” appear in the corner on the little bell icon in either application. If you are on mobile and have badges/banners on for the Salesforce app, you may also see this appear. Since we also set up a Target Id in the Custom Notification Action within the Flow, opening and clicking on the notification will redirect the user to the Opportunity in the cause.
Summary
There you have it; your notification alert to users is all set up! For the recipients who are active Salesforce users, this in-app notification is an excellent alternative to emails – saving the time to navigate to another tab or application.
Enjoy this wonderfully simple but powerful, out-of-the-box notification option!
The Author
Andreea Doroftei
Andreea is a Salesforce Technical Instructor at Salesforce Ben. She is an 18x certified Salesforce Professional with a passion for User Experience and Automation.
Hi Yelena,
Great post! This is really helpful. I tried it and works just fine. However, to access new Desktop notifications you HAVE to click the bell icon. If I am already logged in to Salesforce and a notification is published, I would ideally want it to just float up in the top right corner and an ability to close it, mark it as read etc.
Is there a way to do that?
Hi Ashish,
Unfortunately, I had a similar experience which is why I liked the mobile version of the notifications more, as you could get the badge to appear on the screen. I was not able to find a way to create a badge like notification for the desktop. The experience is the same though in both mobile and desktop, that it just shows in the bell if you are in the app.
Thanks,
Lena
in iOS it will depend on your personal settings for the Salesforce application. You will get the bell indicator, plus either badge on the top or on the Locked Screen depending on your settings.
Hello Yelena,
thanks for sharing this.
I've just recently set up "major incident (push) notifications" in our org by using process builder, a chatter group and the mobile app.
With the right configurations you get the app to push the chatter post on the device.
What are the advantages of the "Custom Notification" method?
"UserXYZ mentioned the group123 in a post" or "UserXYZ posted in the group123" would be dropped, guess that is cool enough to give it a try …
Any other advantages to the chatter model?
Best Regards,
Heiko
This process works great, however we have issue with special characters being included in the Notification Body. Is it possible to remove the special characters?
Hi,
I have followed all the steps given, but not getting notification,
But in the same process builder I am updating one field that is working fine.
What could be the reason.
Thanks
I learned that if you are in the middle of process builder, and create the notification type in another screen, you will need to exit right out of PB and go back in again for it to appear in the list of notification types.
Desktop notifications appear for users, however, users are receiving others opportunity desktop alerts. Is their a solution to this? I need users to only receive alerts to records they own.
Is there a way to clear notifications from the drop down? They seem to stay in the drop down notification widget even after clicking on it or marking as read. Or do they get cleared out after a certain amount of time?
Comments: