Blog

CRM automation: connecting HubSpot, Pipedrive or Salesforce without wrecking your data

CRM automation guide: map your data flows, give each field one owner, stop duplicates in HubSpot, Salesforce and Pipedrive, and design for API limits.

By Rokibul Hasan8 min read

  • CRM
  • Automation
A customer support agent wearing a headset, seen from the side.

Most complaints about a CRM are really complaints about its data: three records for one customer, a deal sitting in a stage it left weeks ago, a phone number wiped by a blank field on a form. CRM automation can fix that or make it far worse, because software repeats a mistake faster than any person.

This guide is for whoever looks after the CRM at a small or mid-sized company, and for the owner paying for it. It covers how data should flow between your CRM and the systems around it, who should own each field, how HubSpot, Salesforce, Pipedrive and Zoho decide that two records are the same person, and the API limits an integration has to respect. What your sales team should automate is a separate question, covered in sales automation.

I build APIs and integrations, and the rules here apply to any of them. The CRM specifics come from each vendor's documentation, read in November 2026.

CRM automation starts with a map of your data

Before any workflow, list what moves in and out of the CRM. For a typical small business the map looks like this:

Data Starts in What the CRM needs Direction
New lead Website form, ad platform, chat Contact, source, consent Into the CRM
Orders or subscriptions Store or billing system Last order, lifetime value Into the CRM, read-only
Invoices Accounting software Paid or overdue flag Into the CRM, read-only
Won deal The CRM Trigger for a project or invoice Out of the CRM
Marketing consent Whichever tool captured it Current state and date Both ways, newest wins

Notice how few rows are two-way. Most people ask for "a two-way sync" when they need several one-way flows, and one-way flows are far easier to keep correct.

Give every field one owner

Duplicates get the attention, but quiet overwrites do more harm. The fix is a short table, written down: field, owning system, who may change it.

  • One system owns each field. Billing owns the invoice address. The CRM owns the deal stage. Everyone else reads.
  • Blanks never overwrite values. An optional phone field left empty on a form should change nothing.
  • Store each system's ID on the record. A customer ID from billing is a far better link than a name.
  • Two-way sync only where people truly edit both sides, with a rule for who wins.

HubSpot's Data Sync shows what that rule looks like in practice. Each sync is two-way or one-way, and a conflict setting names the app that "will overwrite the other when there are data discrepancies". It checks for changes every five minutes, and custom field mappings need a paid Data Hub subscription, so a simple sync that looks free can stop being free once your own fields are involved.

How each CRM decides two records are the same

Matching is where integrations go wrong first, and every CRM does it differently.

CRM What it matches on The catch
HubSpot Contacts by email, companies by primary domain. Batch upsert takes email or a custom unique property Companies created through the API are not deduplicated by domain. Partial upserts are not supported when email is the idProperty
Salesforce Upsert by External ID through a PATCH request Several matches return HTTP 300 and nothing is written. A field not marked Unique needs extra permissions
Pipedrive Merge Duplicates flags the same name plus the same phone, email or organisation This is clean-up after the fact, so an integration should look a person up first. Merges cannot be undone
Zoho CRM Upsert checks duplicate_check_fields in the order you give. Defaults include Email for Contacts and Leads Deals default to Deal_Name, so two deals with the same name match unless you set your own field

The practical answer is to use your own key wherever you can. People change email address and use two at once; a customer number stays put. In HubSpot, that means creating a custom unique property and upserting on it:

POST /crm/v3/objects/contacts/batch/upsert
{
  "inputs": [
    {
      "idProperty": "customer_id",
      "id": "C-10482",
      "properties": { "phone": "+442079460000" }
    }
  ]
}

HubSpot takes up to 100 records per batch and allows up to ten unique-value properties per object, though forms cannot use them. Whatever the CRM, normalise before matching: lower-case emails, trim spaces, and store phone numbers in one international format.

Five ways CRM automation makes data worse

The race. A form and a store webhook arrive within the same second. Both search, neither finds a match, both create a contact. Use a single upsert on a unique key in place of search-then-create, and process changes to the same record one at a time.

The loop. A CRM update syncs to billing, billing writes back, the CRM sees a change and syncs again. Give the integration its own user, ignore changes made by that user, and skip any write where the value has not changed.

The silent gap. Webhooks are not a guarantee. Pipedrive's Webhooks v2 expects a reply within 10 seconds and retries after 3, 30 and 150 seconds. Ten failed first attempts ban the webhook for 30 minutes, events arriving during a ban are lost, and three days without a successful delivery deletes it. Only a scheduled reconciliation job, comparing the two systems, will show you what went missing.

The renamed stage. Someone tidies a pipeline, and a workflow matching the old label stops firing with no error. Use internal IDs in integrations, and keep a list of what depends on what.

The bulk import. One spreadsheet of old contacts sets off every automation that listens for new records. Pause or filter workflows before an import, and tag the imported rows so you can find them.

Limits your integration has to respect

Rate limits decide how an integration has to be built, so check them before you design a nightly job.

HubSpot's limits for privately distributed apps are 100 requests per 10 seconds and 250,000 a day on Free and Starter, and 190 per 10 seconds on Professional and Enterprise, with 625,000 and 1,000,000 a day. The daily figure is shared across every app in the account.

Pipedrive works differently. A company gets a daily token budget of 30,000 multiplied by a plan multiplier and the number of seats, and each call costs tokens. A search costs 40 and a single update costs 10.

A worked example: five seats on Growth, which has a multiplier of 2, gives 300,000 tokens a day. Searching for a person and then updating them costs 50, so that budget covers 6,000 records. A nightly job that re-checks 10,000 contacts this way runs out of budget part-way, then gets 429 errors until the reset at midnight in the server's timezone, which may not be yours, and takes every other integration on the account down with it.

The design response is the same everywhere: send only what changed, use batch endpoints, queue the work, and back off when you see a 429.

Native sync, connector or custom integration

Option Fits when Watch for
Native sync or marketplace app Common tools, standard fields Fixed mappings; custom fields can cost extra
No-code connector A few one-way flows at low volume Search-then-create races, per-task billing, thin error handling
Custom integration Your own keys, several systems, reconciliation, an audit log Someone has to own and maintain it

Use the first option that works. A native sync maintained by the vendor beats anything you have to look after. Workflow automation tools compares the connectors, and Zapier vs Make vs n8n covers what they cost at volume.

Check plan gates as well. Inside HubSpot workflows, "Send a webhook" and "Custom code" need Data Hub Professional or Enterprise, so calling your own service from a workflow may mean a second subscription. That sort of connection is custom work that I quote from a brief.

Automations worth having inside the CRM

Once data flows cleanly, the internal rules are simple, and these earn their keep:

  • A task when a deal has had no activity for a set number of days.
  • A flag when a record is missing a field that a later step depends on.
  • An alert to the account owner when a linked invoice goes overdue.

Give every automation a named owner. A CRM full of unowned workflows becomes a system nobody dares to change.

A monthly check that keeps it honest

Thirty minutes a month catches most drift:

  1. Count new duplicates and find which source made them. Fix the source, then merge.
  2. Compare totals between billing and the CRM. A gap means a flow is leaking.
  3. Follow ten recent records from first touch to now, and see whether the history makes sense.
  4. Read the error log for failed syncs, and confirm someone gets told when one fails.
  5. List automations with no owner, and switch off any that nobody claims.

FAQ

Should a CRM integration sync both ways?

Usually not. Two-way sync is only needed when people genuinely edit the same field in both systems, and then you need a rule for which side wins. Most flows are one-way: orders and invoices into the CRM as read-only information, won deals out to billing or project tools. Every extra two-way field adds a chance of loops and overwrites, so start one-way and add a second direction only when you can name who needs it.

How do I stop an integration creating duplicate contacts?

Match on a stable key and let the CRM insert or update in a single call, instead of searching first and creating afterwards. HubSpot's batch upsert, Salesforce's external ID upsert and Zoho's upsert endpoint all work that way. Normalise email addresses and phone numbers before sending them, process changes to the same record one at a time, and review new duplicates each month to find which source is still creating them.

Do I need to clean my CRM before automating it?

Clean what the automation will read, at least. A routing rule based on country misfires if the country field is half empty, and a sync that matches on email multiplies the duplicates you already have. You do not need a perfect database first. Merge the obvious duplicates, fix the few fields your first automation uses, make those fields required on new records, and deal with older data gradually through a monthly check.

If your CRM and the systems around it have drifted apart, send me a short brief: which CRM and plan you are on, what it needs to talk to, which system you trust for customer details and roughly how many records change a day. Send it through the contact page, read about API and backend development, or see sales automation for what to do with clean data once you have it.