I worked for an organization that uses Salesforce to manage data security. We set up the organization-wide default to be private so that no one could access other users’ data. But now, we need to give other users access to some records. To achieve this requirement, we have a sharing rule feature in Salesforce.
Here, I will explain Salesforce sharing rules and their types, and then show you how to create an owner-based and a criteria-based sharing rule in Salesforce. Additionally, I will explain manual sharing and how to set up manual sharing in Salesforce.
Sharing Rules in Salesforce and Its Types
A Salesforce sharing Rule allows us to extend access to records beyond what is granted by the organization’s defaults. Sharing Rules provide users access to records they do not own or usually cannot see based on criteria such as role, public group, or record ownership.
The Sharing Rule helps users share records based on conditions. We use it for objects whose organization-wide defaults(OWD) are set to public, read-only, or private. When creating sharing rules, we can set the level of access (read-only or read/write).
Types of Sharing Rules
- Owner-Based Sharing Rules: In Salesforce, owner-based sharing rules extend access to records based on their ownership. This means that users who own certain records can share them with other groups or roles.
- Criteria-Based Sharing Rules: In Salesforce, criteria-based sharing rules are used when we want to share records that meet particular criteria or conditions.
- Manual Sharing: Manual sharing in Salesforce allows us to grant specific users access to records (such as accounts, opportunities, or cases) that they usually don’t see.
Create an Owner-Based Sharing Rule in Salesforce
Using the following steps, we will see how to create an owner-based sharing rule.
- Go to Setup. -> Home Page. -> Quick Find Box search for ‘Sharing Settings‘ and click on it.

- Scroll down to the Sharing Rules section and click the New button for the object you want to create a sharing rule for. Here, I’m creating on Lead Object.

- Now, enter the Label, and the Rule Name will automatically populate.

- In the Rule Type field, select the Based on Record Owner option.

- In Lead: Owned by members of the option, we can select Public Group, Queues, Roles, Roles & Subordinates. Here, I have chosen Roles.
- Then, in the next dropdown list, you will see all the roles you need to select based on which roles you want to share records. Here, I want to share records owned by the Marketing Team.

- Here, you need to select with whom you want to share records. I have selected Roles, but a different role team.

- In the Sharing Rule, we can extend access to users or groups, but cannot restrict them, as they already have access. I have selected the access as Read/Write.
- After setting up all the steps, click on the Save button.

- As we click on the Save button, a pop-up window will appear on the screen for confirmation to create a sharing rule. In this window, click on the OK button.

- As we click on the OK button for confirmation, here you can see the sharing rule has been created successfully.

This is how we can create an owner-based sharing rule in Salesforce.
Create a Criteria-Based Sharing Rule in Salesforce
Using the following steps, we will see how to create a criteria-based sharing rule.
- Go to Setup. -> Home Page. -> Quick Find Box search for ‘Sharing Settings‘ and click on it.
- Scroll down to the Sharing Rules section and click the New button for the object you want to create a sharing rule for. Here, I’m creating a Lead Object.
- Now, enter the Label, and the Rule Name will automatically populate.

- This time, in the Rule Type field, select the Based on Criteria option.

- In this step, we will define the criteria for sharing. To do so, go to the Criteria section and specify the Field, Operator, and Value. If the specified criteria for the records are met, those records will be shared.
- In this example, I have applied the criteria for City, Country, and Industry fields.

- Specify the users who get access to the data. In the field Share with, select a category from the first dropdown list and a set of users from the second dropdown list.
- In this example, I have selected the Category Roles and Subordinates and the Set of Users as the Marketing Team.

- In this step, select the users’ access level. In this case, I have selected Read/Write as the access. At last, click on the Save button.

- As we click on the Save button, a confirmation message will appear on the screen; click on the OK button.

- The criteria-based sharing rule will be created in the object’s sharing rules section. In this example, I have specified the sharing rule in the Leads object so it will be visible in the Lead Sharing Rules.

In this way, we can set up Criteria-Based Sharing Rules in Salesforce.
What is Manual Sharing in Salesforce
Using the criteria-based and owner-based sharing rules, the records are shared in groups, but manual sharing takes place when we need to share a particular record with a specific user, group, or role.
Manual sharing is the process of manually granting access to a particular record. When sharing the records manually, we can give the people with whom we want to share read-only or read/write access.
Who can share Salesforce Records?
- Administrator.
- A user who has full access to records.
- Record Owner.
- The user whose role is above the record owner in the role hierarchy.
Set up Manual Sharing in Salesforce
Before sharing records manually, you need to set up and activate some functionality. The following steps can help you achieve manual sharing in Salesforce.
- On the Home Page, click the “Gear icon,” then select “Setup” from the dropdown. On the setup page, “Quick Find Box” -> Search ”Sharing Setting” -> Click on “Sharing Setting.”

- Click on the Edit Button to activate it.

- Scroll down in “Other Settings” -> click on “Manual User Record Sharing” -> Save it.

Share Records Using Manual Sharing in Salesforce
Once you activate “Manual User Record Sharing” to share records manually, follow the steps below.
- Select the object. Here, I have selected the “Employee” object.
- Go to the Record that you want to share.
- Click on the dropdown arrow on the standard button bar.
- You will find the “Sharing” button; click it.

- Select the user to whom you want to share the record.
- Select employee access level. Here, I have selected “Read-only” -> Click on Save.
- Read Only – The receiver user can only read this record.
- Read/Write – The receiver user can edit this record.

In this way, we can set up manual sharing in Salesforce.
Conclusion
In this Salesforce tutorial, we learned about the sharing rules in Salesforce. We have seen what a sharing rule is, the types of sharing rules, how to create an owner-based sharing rule, and criteria-based sharing rules in Salesforce, with examples and step-by-step explanations.
Additionally, I explained what manual sharing is and how to set up manual sharing in Salesforce so that we can share a particular record with a specific user, group, or role.
You may like to read:
I am Bijay Kumar, the founder of SalesforceFAQs.com. Having over 10 years of experience working in salesforce technologies for clients across the world (Canada, Australia, United States, United Kingdom, New Zealand, etc.). I am a certified salesforce administrator and expert with experience in developing salesforce applications and projects. My goal is to make it easy for people to learn and use salesforce technologies by providing simple and easy-to-understand solutions. Check out the complete profile on About us.