HubSpot to Salesforce Migration: No Data Loss Guide
In this article
Migrating from HubSpot to Salesforce is a major project, but with careful planning you can move your contacts, companies, deals, and custom objects without losing data. This guide walks you through a safe, step-by-step process—from cleaning your data to validating the final import. The key is to treat it as a data migration, not just a copy-paste job.
What You'll Need
- Admin access to both HubSpot and Salesforce (at least System Administrator in Salesforce, and Account Owner or Super Admin in HubSpot)
- A paid Salesforce edition that supports Data Import Wizard (all standard editions) or Data Loader (Professional, Enterprise, Unlimited, and Developer)
- Data Loader installed if you're importing more than 50,000 records or need scheduled imports
- A CSV export of all HubSpot data you want to move
- An Excel or Google Sheets tool to clean and map data
- A backup of your HubSpot data stored securely (e.g., cloud drive)
- A clear understanding of which HubSpot objects map to which Salesforce objects (e.g., Contacts, Companies, Deals, Tickets)
Step-by-Step
- Audit your HubSpot data. Before exporting, review what you actually need. Go to Contacts, Companies, Deals, Tickets, and any custom objects. Identify duplicate records, incomplete fields, and outdated entries. Decide what to keep and what to archive. This step prevents importing junk that will clutter Salesforce.
- Export from HubSpot. For each object, navigate to the list view, select all records (or a specific date range), and click Export. Choose CSV format. For custom objects, you may need to use the API or a third-party tool if the standard export doesn't cover them. Export all related lists (e.g., contact lists, company lists) separately.
- Back up everything. Save all exported CSV files to a secure location. Also download any attachments, notes, or files you might need. Even if you're moving to Salesforce, keep this backup for at least six months after migration.
- Clean and deduplicate your data. Open each CSV in a spreadsheet tool. Remove blank rows, fix formatting (dates, phone numbers, zip codes), and standardize values (e.g., state abbreviations). Use a deduplication tool or manually identify duplicate contacts/companies by email or name. Decide which record is the master and merge or delete the rest.
- Map HubSpot fields to Salesforce fields. Create a mapping document. For each HubSpot field, note the corresponding Salesforce field (e.g., HubSpot 'Email' → Salesforce 'Email', HubSpot 'Phone' → Salesforce 'Phone'). Be aware of field types: text, number, date, picklist, checkbox. For picklists, ensure the Salesforce picklist values match the HubSpot values exactly, or map them to new values.
- Prepare Salesforce for import. Log into Salesforce. Go to Setup → Object Manager and review the objects you'll import into. Make sure required fields are present. If you need new fields, create them. Also set up any picklist values that don't exist yet. Disable validation rules, required field constraints, and workflow rules that might block import—or at least test with them on.
- Create a test import. Start with a small sample (e.g., 10-20 records) to test your mapping. Use the Data Import Wizard (Setup → Data Management → Data Import Wizard) for simple imports. For larger or more complex imports, use Data Loader. Run the test import and check the results. Fix any errors before proceeding.
- Import Companies first. In Salesforce, Company (Account) records are the parent of Contacts and Deals. Import companies using the Data Import Wizard or Data Loader. Map external ID fields if you have them (e.g., HubSpot company ID) to prevent duplicates. After import, note the Salesforce Account IDs.
- Import Contacts. Use the Account ID you just created to link contacts to companies. In the import file, include the Account ID column. If you don't have a match, you can create contacts without an account, but it's better to link them. Use the Data Import Wizard for up to 50,000 records; Data Loader for more.
- Import Deals and other objects. Deals in Salesforce are similar to HubSpot deals. Map the deal stage, amount, close date, and associated contact/company. Use the Contact ID and Account ID from the previous imports. For custom objects, create them in Salesforce first, then import.
- Import activities and notes (optional). Salesforce has tasks and events for activities. You can import emails, calls, and meetings as tasks. Notes can be imported as Salesforce notes or attachments. This is time-consuming, so prioritize what's essential.
- Re-enable validation rules and workflows. After the import, turn back on any rules you disabled. Test that they work correctly with the new data.
- Validate the data. Run reports in Salesforce to compare record counts with HubSpot. Spot-check random records for accuracy. Check that key fields like email, phone, and company names are correct. Verify that relationships (contacts to companies, deals to contacts) are intact.
- Communicate with your team. Notify users of the migration date and provide training on the new system. Set expectations about any data that didn't migrate (e.g., email templates, automation workflows).
- Decommission HubSpot (only after everything is verified). Once you're confident, you can cancel your HubSpot subscription. Keep your backup files accessible.
Common Mistakes
- Skipping data cleaning. Importing duplicates and dirty data leads to a messy Salesforce org that's hard to fix later.
- Not mapping picklist values. If HubSpot has a value like 'Prospect' and Salesforce has 'Prospecting', the import will fail or create a blank field.
- Ignoring required fields. Salesforce has required fields like Account Name for contacts. If your CSV lacks them, the import will error.
- Importing in the wrong order. Companies must come before contacts, and contacts before deals. Otherwise, you'll get orphan records.
- Forgetting about file attachments. Standard exports don't include attachments. You'll need to manually transfer them or use a third-party tool.
- Not testing with a small sample. Running a full import without a test can waste hours and cause data corruption.
Tips
- Use external ID fields in Salesforce to match records to HubSpot IDs. This prevents duplicates and helps with future syncs.
- Export data in chunks (e.g., by date range) to keep file sizes manageable and reduce the risk of timeouts.
- Use Data Loader for large imports; it's more reliable and can handle bulk operations.
- Create a sandbox environment in Salesforce for practice runs before touching production data.
- Document your field mapping thoroughly—it will help if you need to re-import or troubleshoot.
- Consider using a migration tool like Import2 or Cloudingo if you have complex requirements or limited technical resources.
Troubleshooting
Import fails with field errors. Check the error log file. Common causes: mismatched field types, missing required fields, or picklist values not in Salesforce. Fix the CSV and re-import.
Duplicate records appear. Use the deduplication rules in Salesforce or run a merge process. You can also re-import with external IDs to update existing records instead of creating new ones.
Contacts not linking to companies. Ensure you have the correct Account ID in your CSV. If you used external IDs, verify the external ID field is populated correctly.
Data looks wrong (e.g., dates shifted). Check the date format in your CSV. Salesforce expects ISO 8601 (YYYY-MM-DD). Re-import with corrected formats.
Import times out. Split the file into smaller batches (e.g., 10,000 records at a time). Use Data Loader with batch size settings.
You realize you missed a field. Don't panic. You can export the Salesforce data, add the missing field, and re-import using an external ID to update existing records.
Frequently Asked Questions
Can I migrate email templates and marketing automation?
No, those are not standard data objects. Email templates, workflows, and landing pages do not export as data. You'll need to recreate them manually in Salesforce Marketing Cloud or Pardot.
How long does the migration take?
It depends on data volume and complexity. A small org (under 10,000 records) might take a few days; a large enterprise with custom objects could take weeks. Plan for at least a week of dedicated work.
Will my HubSpot deal stages map to Salesforce?
Only if you set up matching picklist values. You'll need to create the same stages in Salesforce or map them to existing ones. The import will fail if a stage value doesn't exist.
Can I keep my HubSpot IDs for reference?
Yes, you can store them in a custom field in Salesforce (e.g., 'HubSpot ID'). This helps with auditing and future integrations.
What about custom objects in HubSpot?
You'll need to create equivalent custom objects in Salesforce and map fields manually. The export may not include all custom object data—you might need to use the API.
Do I need to migrate my website tracking code?
No, that's separate. You'll need to install Salesforce tracking code on your website if you want analytics. HubSpot's tracking code will stop working when you cancel.