What Is a Duplicate Rule in Salesforce?
A duplicate rule defines what Salesforce does when a user is about to save a record that looks like an existing one - block it, allow it with a warning, or ju
Updated 2026-09-09
A duplicate rule defines what Salesforce does when a user is about to save a record that looks like an existing one - block it, allow it with a warning, or just report it - based on a matching rule that decides what counts as a match.
In more detail
Duplicate rules and matching rules are two different pieces: the matching rule defines the fuzzy-match logic (close variations of a name, email, or phone count as a match), and the duplicate rule defines the action taken when the matching rule fires.
They operate at save time, on new and edited records. They do nothing about duplicates already sitting in the org - that is an exact-match SOQL audit and a merge, not a rule.
Why it matters for admins
- They are the prevention half of deduplication; SOQL and merge are the cleanup half. Neither one works well without the other.
- Salesforce ships standard matching rules for Account, Contact, and Lead that can be activated without configuration.
- A rule set to Alert rather than Block still lets a duplicate through if the user dismisses the warning, so "we have a duplicate rule" is not the same guarantee as "we have zero duplicates."
Frequently asked questions
- Do duplicate rules stop duplicates that already exist?
- No. They only evaluate records being created or edited going forward. Existing duplicates need a SOQL-based audit and a manual or bulk merge.
- Can a duplicate rule block a save entirely?
- Yes - a duplicate rule can be configured to Block, which prevents the save until the user resolves or confirms the match, or to Allow with an alert, which only warns.
More from the Glossary
- What Is a Change Set in Salesforce?A change set is Salesforce's built-in, point-and-click mechanism for moving configuration - not data - from one connected org to another, most commonly from a
- What Is a Permission Set in Salesforce?A permission set is a collection of settings and permissions that extends a user's access without changing their profile. Permission sets are additive: they g
- What Is a Record Type in Salesforce?A record type lets one object behave differently for different business processes - different page layouts, different picklist values, and different default v
- What Is a Salesforce ID in Salesforce?A Salesforce ID is the unique identifier of a record. It comes in a 15-character case-sensitive form and an 18-character case-insensitive form that is safe fo
- What Is a Sandbox in Salesforce?A sandbox is a copy of your Salesforce org used for development, testing, and training, isolated from production data and users.
- What Is an AI SOQL Builder in Salesforce?An AI SOQL builder turns a plain-English description of the records you want into a runnable SOQL query, using the schema of the org you are working in so the
Related reading
- Admin How-ToHow to Find and Merge Duplicate Records in SalesforceA full workflow for cleaning up duplicate accounts, contacts, and leads in Salesforce - the native merge tool, its record limits, and the SOQL to find what it can't show you.
- SOQL LibrarySOQL Query to Find Duplicate Accounts by NameFind duplicate accounts in Salesforce with a GROUP BY / HAVING SOQL query on Name, then pull the underlying record IDs.
- SOQL LibrarySOQL Query to Find Duplicate Contacts by EmailFind duplicate contacts in Salesforce with a GROUP BY / HAVING SOQL query on Email, then pull the underlying record IDs.
- SOQL LibrarySOQL Query to Find Duplicate Leads by EmailFind duplicate leads in Salesforce with a GROUP BY / HAVING SOQL query on Email, then pull the underlying record IDs.