Revert Merge Operation on HubSpot Records

monster-count-boxes.png

How to Restore Merged HubSpot Records 

Maintaining the integrity of your CRM relies on effective duplicate record management, but merging duplicates can sometimes yield unexpected results. In such cases, you might need to reverse the merge process.

While HubSpot's knowledge base explains that unmerging records is not possible, Insycle offers some workarounds. Although it may not offer a full recovery, Insycle can partially restore merged duplicates and undo the changes to the master records.

Recovering HubSpot Records from Native Merge Operation

This workaround lets you recreate contacts, companies, courses, deals, leads, listings, tickets, and custom objects that were merged using HubSpot’s built-in merge logic.

Process Summary

  1. Remove "Additional Emails" or "Additional Domains" from the master records.
  2. Prepare and clean up the CSV report.
  3. Import merged records back into the CRM.
  4. Fix associations for master records and duplicates.

Step-by-Step Instructions

Merged Contacts: Remove Additional Emails from Master Records

When contact records are merged, the email from the master becomes the primary, and the duplicate record email addresses are added as Additional Email Addresses. These need to be cleared from the master; when duplicate records are added back, the emails should only be on the duplicates to serve as unique identifiers. If not removed, Insycle will see them as existing records rather than new records for import.

When you ran the merge operation, you should have received an email containing the CSV report.

If you can't find the email, you can download the file from the Activity Tracker. Click on the relevant Run ID to download the CSV of records affected by the merge operation.

activity-tracker-merge-duplicate-operation-run-id-w-arrow.png

Open the CSV report and copy the Master (After) Record IDs into a new CSV file. Include only the Record IDs in the new file.

unmerge-duplicate-contacts-csv-masterafter-record-rows-646px.png

In the Data Management > Magical Import module, upload the new CSV of master records

magical-import-unmerge-duplicates-import-masters-select-csv.png

In Step 1, resolve any warnings that appear.

Under Step 2, set the Matching Criteria as the Record ID.

magical-import-unmerge-duplicates-import-masters-step-2.png

In Step 4, under the Bulk Update tab, select the Additional Email Addresses field, and leave the New Value field blank to clear the values.

magical-import-unmerge-duplicates-import-masters-step-4.png

Under Step 5, click the Import button.

Learn more about importing from a CSV using Magical Import.

Merged Companies: Remove Additional Domains from Master Records

When company records are merged, the domains from the duplicates are reassigned to the master record's Additional Domains field. Before restoring merged companies, clear these additional domains from the master. Duplicate records must contain unique domains to serve as matching criteria. If not removed from the master, Insycle will treat them as existing records instead of new imports.

When you ran the merge operation, you should have received an email containing the CSV report.

If you can't find the email, you can download the file from the Activity Tracker. Click on the relevant Run ID to download the CSV of records affected by the merge operation.

activity-tracker-hubspot-merge-companies-run-ID-w-arrow-646px.png

Open the CSV report and copy the Master (After) Record IDs into a new CSV file. Include only the Record IDs in the new file.

unmerge-duplicate-companies-csv-masterafter-record-rows-646px.png

In the Data ManagementMagical Import module, upload the new CSV of company master record IDs

magic-import-hubspot-companies-upload.png

In Step 1, resolve any warnings that appear.

Under Step 2, set the Matching Criteria to the Record ID.

magical-import-unmerge-duplicates-import-masters-step-2.png

In Step 4, on the Bulk Update tab, select the Additional Domains field. Leave the New Value field blank to clear any existing values.

magic-import-hubspot-companies-step-4.png

Under Step 5, click the Import button.

Learn more about importing from a CSV using Magical Import.

Prepare and Clean Up the CSV Report

Open the original "insycle-bulk-merge" CSV report with all of the column and row data.

  1. Remove columns for read-only fields:
    • Record ID
    • Deeplink
    • Create Date
    • Any other read-only fields from the merge
  2. Remove any redundant columns, such as Name or Email
  3. Remove the merge operation columns:
    • Result
    • Message
    • Duplicate Group ID
    • Status

Save the CSV file.

Import Merged Duplicate Records to the CRM

In the Data Management > Magical Import module, upload the updated CSV

Under Step 2, set the Matching Criteria (Email is a good one for contacts, Domain for companies), and set the Records Mode to "Only create net new." 

When you configure your Matching Criteria rules, the data under Step 1 will refresh, and you'll be able to see which records are already in your CRM. The records that Insycle found will become blue links that will open the record in your CRM.

magical-import-unmerge-duplicates-re-import-merged-step-2.png

Under Step 5, click Import.

All the duplicate records should be imported, and the Masters and Master (After) won't, since they already exist.

magical-import-unmerge-duplicates-re-import-merged-step-1.png

Fix Associations for Master Records and Duplicates

Remove Extra Associations from Master Records

When the duplicates were merged, all existing associations from the duplicates were automatically assigned to the master record—these associations need to be removed.

In the RevOps Acceleration > Associate app, you can use the Replace feature to remove any non-primary associations.

For contacts, the Remove non-primary associations between Contacts and Companies template is a good place to start.

Under Step 1, filter for records where the Primary Associated Company ID exists and also include criteria to target the records that have the associations you want to remove. You can use the Last Modified Date to indicate the length of time since this merge was run.

Click Search and check to make sure the records you want to update are what appear in the Record Viewer at the bottom of the page.

associate-hubspot-contacts-step-1-primary-company-24-hrs.png

Under Step 2, select the Replace action and configure the association. Set up the fields for the association your records should have. Don't worry about what currently exists; Insycle will take care of all the cleanup automatically.

bulk-operations-remove-non-primary-associations.png

Preview the changes, and when this looks good, Update the records in HubSpot.

Learn more about using Insycle to add or remove HubSpot associations.

Add Associations to Duplicate Records

By default, HubSpot will automatically associate contact records to companies based on the email domain, but if you need more control over what associations are added or want to make additional associations, you can use the Associate app. 

Explore the templates for an existing solution that may be close to what you need.

In Step 1, filter the contact records down to those you want to associate with companies.

bulk-operations-hubspot-associate-contacts-to-companies-step-1.png

Under Step 2, define the rules that will create the relationship between the contacts and companies. 

bulk-operations-hubspot-associate-contacts-to-companies-step-2.png

Preview the changes, and when this looks good, Update the records in HubSpot.

Learn more about using Insycle to associate HubSpot contacts to companies.

Unmerge HubSpot Records from Insycle's Synthetic Merge

You can recover HubSpot companies, courses, deals, leads, listings, tickets, and custom objects that were merged using Insycle's Synthetic merge. Since Synthetic merge is not compatible with contact records, this unmerge process is not available for them.

Process Summary

  1. For companies, remove additional domains from master records.
  2. Use HubSpot to restore records.
  3. Fix associations for master records.

Step-by-Step Instructions

Remove Additional Domains from Master Records (Companies Only)

When company records are merged, the domains of the duplicates are reassigned to the master record's Additional Domains field. Before restoring the merged companies, these additional domains should be cleared from the master. When you add the duplicate records back, the domains should only be on the duplicate records to be used as the unique identifier. If they are not removed from the master, Insycle will identify them as existing records instead of new records needing to be imported.

Open the CSV report from your email or the Activity Tracker, and extract the Master record rows into a new CSV file. Include only the Record IDs for the rows where the Status is "Master."

unmerge-duplicate-companies-csv-master-record-rows.png

In the Data ManagementMagical Import module, upload the new CSV of company master record IDs

magic-import-hubspot-companies-upload.png

In Step 1, resolve any warnings that appear.

Under Step 2, set the Matching Criteria to the Record ID.

magical-import-unmerge-duplicates-import-masters-step-2.png

In Step 4, under the Bulk Update tab, select the Additional Domains field. Leave the New Value field blank to clear any existing values.

magic-import-hubspot-companies-step-4.png

Under Step 5, click Import.

Learn more about importing from a CSV using Magical Import.

Recover Deleted Duplicate Records

The HubSpot merge API that Insycle uses when merging companies, courses, deals, leads, listings, tickets, and custom objects deletes the duplicate records after the merge. These records can easily be recovered by accessing HubSpot's recycle bin.

In HubSpot, navigate to the object type. Click the Actions menu and select Restore records

hubspot-restore-records.png

All deleted duplicate records from the merge will be available for restoration on the Restore page, complete with all associations, activities, history, and field values.

Learn more about HubSpot's Restore Records feature.

Fix Associations on Master Records

When the duplicates were merged, all existing associations were automatically assigned to the master record—these associations need to be removed. Activities such as notes, emails, or tasks from the duplicates that were assigned to the master record cannot be removed.

In the RevOps Acceleration > Associate app, you can use the Replace feature to remove associations.

Under Step 1, filter for records where the number of associated records > 0 and also include criteria to target the records that you are unmerging. Click Search and check to make sure the records you want to update are what appear in the Record Viewer at the bottom of the page.

bulk-operations-hubspot-associate-companies-to-contacts-step-1.png

Under Step 2, select the Replace action and configure the association. Set up the fields for the association your records should have. Don't worry about what currently exists; Insycle will take care of all the cleanup automatically.

bulk-operations-hubspot-associate-companies-to-contacts-step-2.png

Preview the changes, and when this looks good, Update the records in HubSpot.

Learn more about using Insycle to add or remove HubSpot associations.

Note that there is no cleanup action needed for the duplicate records since HubSpot's restore function includes all associations and activities.

How to Determine Whether Native Merge or Synthetic Merge Was Used

There are a few notable differences that can identify which merge method was used by looking at the Record ID in the CSV report generated by the merge operation.

Native HubSpot Merge

A unique Record ID is created for the new resulting merged record. This will populate the Master (After) Record ID field in the CSV.

merge-duplicates-hubspot-contacts-native-merge-csv-646px.png

Insycle’s Synthetic Merge

The Record ID from the master record is kept when the other duplicates are merged into it. There is no new record. The same Record ID appears in both the Master and Master (After) fields in the CSV.

merge-duplicates-hubspot-contacts-synthetic-merge-csv-646px.png

Tips for Backing Up Data Before Merging

Backing Up Fields from Insycle

When setting up your merge operation in the Merge Duplicates module, add extra fields to be included in the CSV report so you have the data later for undoing changes and/or just for general review.

Under Step 2, click the icon-gear-18x18.png gear icon in the header.

merge-duplicates-contacts-step-2-layout-gear.png

On the Layout tab, add any extra fields to the Visible Fields list.

merge-duplicates-hubspot-contacts-job-title-layout-646w.png

The fields will be included in the CSV report.

merge-duplicates-hubspot-contacts-job-title-csv-646w.png

Backing Up Complete Records from HubSpot

Before running a large merge operation, export all records directly from HubSpot to a CSV file.

In HubSpot, navigate to the object type and click Export. Select the file format, "CSV," and include "All properties on records."

hubspot-export-records.png

Frequently Asked Questions

Will the HubSpot 'Restore records' feature work if the Salesforce Sync is Active?

Yes, HubSpot's Restore Records feature can work with Salesforce sync active. When you restore a record in HubSpot, the changes are reflected in your HubSpot database. If the Salesforce sync is active, these changes will eventually be reflected in Salesforce, depending on the sync settings and frequency.

Additional Resources

Related Articles

Related Blog Posts