January 11, 2025

In Salesforce, matching rules define how records are compared to find potential duplicates, and duplicate rules decide what happens when a match is found, whether to block, alert, or allow the entry. You set them up in Setup by activating or building a matching rule for an object, then creating a duplicate rule that references it and choosing its action. Together they are Salesforce duplicate rules in practice, the platform's built-in duplicate management, and this guide walks through setting up both.
Duplicate records are one of the most common and costly data-quality problems in any CRM. They waste time, split a customer's history across records, and quietly undermine reports. The good news is that Salesforce gives you the tools to catch and prevent duplicates without extra software. This guide covers what matching rules and duplicate rules do, how to set each up, how to test them, and how to keep your data clean over time.
Here is the quick view before the detail.
Matching rules and duplicate rules in Salesforce work as a pair to power its native duplicate detection. One finds possible duplicates; the other decides what to do about them. Understanding the split is the key to setting them up well.
Matching rules set the standard by which Salesforce compares records. A matching rule can check whether two contacts share the same email address, or whether two accounts have a similar name and the same city. Matching criteria can be exact or fuzzy, so "Bob" and "Robert" can still match when you want them to.
Duplicate rules act on what the matching rule finds. When a match is detected, the duplicate rule decides whether to block the save, warn the user with an alert, quietly report it, or allow it. In short, matching rules find similar records, and duplicate rules manage what happens next.
Salesforce ships with standard matching rules for accounts, contacts, and leads that are ready to activate. Because every business handles data differently, you can also build custom matching rules for your own fields and logic. Here is the matching rule setup.
A matching rule does nothing on its own; it only supplies the logic a duplicate rule calls on. So activate it, then move to the duplicate rule that will put it to work.

With a matching rule active, create the duplicate rule that acts on it. This is the duplicate rule setup that turns detection into prevention.
The action you choose is the heart of your duplicate prevention, and the duplicate rule criteria you set decide how strict the record matching becomes. The table below explains each option and when to use it.
Most duplicate management rules are set per object, because a duplicate means something different on each one. Salesforce provides standard rules for the three objects where duplicates cause the most trouble, and you can tailor each.
Handled together, these three cover the bulk of everyday duplicate record management. Set the standard rules live first, watch how they behave, then adjust the criteria per object as your data teaches you what a real duplicate looks like.
Never trust a new rule until you have seen it work. Test with sample data before you rely on it, so you know your duplicate check behaves as intended.
Watch for two errors as you test. A false positive flags a record that is not really a duplicate, and a false negative misses a real one. If either shows up, tune your matching criteria: tighten it to catch more real duplicates, or loosen it to stop over-flagging. Schedule regular checks as your database grows, and train your team to read the alerts correctly.
Rules stop new duplicates, but you also need a plan for the ones already in your org. That is where data deduplication, record deduplication, and merging come in.
To merge duplicate records in Salesforce, you can use the native merge feature on accounts, contacts, and leads to combine two or three records into one, keeping the field values you choose. For large-scale cleanup, third-party AppExchange tools such as DemandTools, Cloudingo, or Duplicate Check handle bulk deduplication and deeper analysis than the native tools alone. These are worth considering when a one-time cleanup is too big to do by hand, or when you import data often and want to prevent duplicate records at the point of entry.
Whatever route you take, test any bulk tool or import in a sandbox first, so your live data stays safe while you confirm the results. Community walkthroughs on SFDCStop and Salesforce Geek are useful when you compare cleanup approaches.
A few Salesforce duplicate management best practices keep your records clean long after setup.
Strong data hygiene is a habit, not a project. Pairing these rules with a regular Salesforce health check keeps your CRM data quality high as the org grows. The Salesforce Admins hub and Salesforce Ben both publish helpful guidance on keeping records clean.
A matching rule defines how Salesforce compares records to find potential duplicates, using criteria like email or name. A duplicate rule decides what happens when a match is found, whether to block, alert, report, or allow the record. They always work together.
Go to Setup, activate or create a matching rule for the object, then create a duplicate rule that references it. Choose the action, such as block or alert, name any profiles that can override it, and activate the rule. Test with sample records before you rely on it.
Yes. Salesforce provides standard matching rules and duplicate rules for accounts, contacts, and leads that you can activate right away. You can also build custom matching rules when your data needs criteria the standard rules do not cover.
Use the native merge feature on accounts, contacts, or leads to combine records and keep the field values you choose. For large volumes, third-party tools handle bulk deduplication. Always test a bulk merge in a sandbox first.
Activate duplicate rules set to block or alert on your key objects, keep your matching criteria current, and add a data-quality routine for imports. Together these prevent most duplicate records from ever entering the system.
Clean data starts with the right rules. Set up matching rules to define what a duplicate looks like, add duplicate rules to decide what happens when one appears, test both with sample records, and merge the duplicates you already have. Keep the criteria current, and your Salesforce CRM data quality stays high as the org grows.
If you would like help designing rules that fit your data, or a one-time cleanup to start fresh, Minuscule Technologies offers Salesforce implementation and data-quality services built around your org. As a certified Salesforce consulting partner and Salesforce implementation partner, we help you build a duplicate-free database that stays that way. Contact us today to get started.
You've seen what's possible. Now, let's make it happen for your business. Whether you need an end-to-end Salesforce solution, a complex integration, or ongoing managed services, our team is ready to deliver.
Schedule a Free Strategic Call