web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Answered

How to automate the removal of duplicate Accounts and Contacts in Dynamics 365 Sales?

(3) ShareShare
ReportReport
Posted on by 458
Is there a way to automate the removal of duplicate Accounts and Contacts for existing records in Dynamics 365 Sales?
Categories:
I have the same question (0)
  • Verified answer
    Daivat Vartak (v-9davar) Profile Picture
    7,829 Super User 2025 Season 2 on at
    How to automate the removal of duplicate Accounts and Contacts in Dynamics 365 Sales?
    Hello ArchitectMadhan,
     
    Yes, there are several ways to automate the removal of duplicate Accounts and Contacts in Dynamics 365 Sales. The best approach depends on your specific needs and technical resources. Here's a breakdown of the most common methods:
     
    1. Duplicate Detection Rules and Jobs (Built-in Functionality):
    • How it Works:
      • Dynamics 365 has built-in duplicate detection rules that you can configure to identify potential duplicates.  
      • You can then run a duplicate detection job to find existing duplicates in your data.  
    • Steps:
      1. Create Duplicate Detection Rules:
        • Go to Settings > Data Management > Duplicate Detection Rules.
        • Create rules for Accounts and Contacts, specifying the criteria for identifying duplicates (e.g., matching names, email addresses, phone numbers).  
        • Publish the rules.
      2. Run Duplicate Detection Jobs:
        • Go to Settings > Data Management > Duplicate Detection Jobs.
        • Create a new job for Accounts and Contacts.
        • Select the duplicate detection rules you created.
        • Schedule the job to run periodically or run it manually.
      3. Merge Duplicates:
        • Once the job completes, you can review the detected duplicates and merge them.
        • Dynamics 365 provides a merge interface that allows you to choose which fields to keep from each duplicate record.  
    • Automation:
      • You can schedule duplicate detection jobs to run automatically at regular intervals.  
    • Limitations:
      • The merge process is primarily manual, requiring you to review and merge duplicates one by one (or in batches).
      • It is not very good at automatically deleting records.
      • It requires good rule creation.
    2. Power Automate (Microsoft Flow):
    • How it Works:
      • You can create Power Automate flows to automate the duplicate detection and removal process.  
      • Flows can be triggered on a schedule or when new records are created or updated.  
    • Steps:
      1. Trigger:
        • Use a "Recurrence" trigger to run the flow on a schedule.
        • Or, use a "When a record is created or modified" trigger.
      2. List Records:
        • Use the "List records" action to retrieve Accounts or Contacts.
      3. Duplicate Detection Logic:
        • Implement logic to identify duplicates based on your criteria. This might involve:
          • Comparing field values.
          • Using the "Detect duplicates" action.
        • Power Automate has actions to detect duplicates.  
      4. Merge or Delete Duplicates:
        • Use the "Update a record" action to merge duplicate records.
        • Or, use the "Delete a record" action to delete duplicate records.
      5. Error Handling:
        • Implement error handling to manage potential issues during the process.
    • Advantages:
      • Provides more flexibility than built-in duplicate detection.
      • Allows for automated merging or deletion of duplicates.  
    • Considerations:
      • Requires some Power Automate skills.
      • Carefully test the flow to avoid unintended data loss.
    3. Custom Plugins or Workflows (Advanced):
    • How it Works:
      • You can develop custom plugins or workflows to implement more complex duplicate detection and removal logic.
      • Plugins are server-side code that can be triggered by various events.  
      • Workflows are a no code server side process.  
    • Advantages:
      • Provides the most flexibility and control.
      • Allows for complex logic and integrations.
    • Considerations:
      • Requires development expertise.
      • Can be more complex to maintain.
    4. Third-Party Data Quality Tools:
    • How it Works:
      • Several third-party data quality tools integrate with Dynamics 365 and provide advanced duplicate detection and data cleansing capabilities.
      • These tools often offer more features and automation than the built-in functionality.
    • Advantages:
      • Provides advanced features and automation.
      • Can improve data quality significantly.
    • Considerations:
      • Requires purchasing and configuring a third-party tool.
    Recommendations:
    • Start with Duplicate Detection Rules and Jobs: This is the easiest and most straightforward approach for basic duplicate detection.
    • Use Power Automate for More Automation: If you need to automate the merging or deletion of duplicates, Power Automate is a good option.
    • Consider Third-Party Tools for Advanced Needs: If you have complex data quality requirements, consider using a third-party tool.
    • Test Thoroughly: Always test your duplicate detection and removal processes thoroughly in a non-production environment before implementing them in production.
    • Backup Your Data: Before making any changes to your data, ensure you have a recent backup.
     
    If my answer was helpful, please click Like, and if it solved your problem, please mark it as verified to help other community members find more.
    If you have further questions, please feel free to contact me.
     
    My response was crafted with AI assistance and tailored to provide detailed and actionable guidance for your Microsoft Dynamics 365 query.
     
    Best Regards,
    Daivat Vartak
     
  • Suggested answer
    Tom_Gioielli Profile Picture
    2,056 Super User 2025 Season 2 on at
    How to automate the removal of duplicate Accounts and Contacts in Dynamics 365 Sales?
    The duplicate detection jobs will find the duplicate values, but they require a user to manually determine if the records should be merged together (along with what fields to include from each record).
     
    If you knew your duplicate rules ahead of time, you in theory could use a Dataflow to find duplicates and mark them in some way, or do it through excel. You could then use a Power Automate flow to run the Merge Action (Microsoft.Dynamics.CRM) | Microsoft Learn action to merge them together.
     
    However, at the end of the day I would recommend manually running through the duplicates and cleaning them up. It will probably suck the first time you do it, but if you keep to it regularly it won't be too bad. After that, identify what about your process or organization is causing all of these duplicates in the first place and address the issue at the source.
     
    If this answer helped, please consider marking as verified.
  • Adam_Travers Profile Picture
    329 on at
    How to automate the removal of duplicate Accounts and Contacts in Dynamics 365 Sales?
    Not using the out of box Dynamics Duplicate Check functionality and Flow as far as I’m aware. We use a 3rd Party application for this (Data8) 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Andrés Arias – Community Spotlight

We are honored to recognize Andrés Arias as our Community Spotlight honoree for…

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
Daniyal Khaleel Profile Picture

Daniyal Khaleel 130

#2
DAnny3211 Profile Picture

DAnny3211 97

#3
Abhilash Warrier Profile Picture

Abhilash Warrier 66 Super User 2025 Season 2

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans