ERP CRM integration connects the CRM, where sales manages accounts, deals and quotes, with the ERP, where finance and operations keep the customer master, prices, stock, orders and invoices, so each record is typed once and shows up wherever people need it. Most integrations move a short list of things: accounts and contacts, products and price lists, the won deal that becomes a sales order, and invoice, payment and credit status flowing back so salespeople can see them. The API calls are the easy part. Most of the work is deciding which system owns each field, and what happens when the two disagree.
Some of the advice below comes from integrations we build for clients: live API links between Oplist's rostering platform and private hospitals' HR and payroll systems, monthly supplier data feeds, and migrations out of legacy software. Where a point comes from one of those projects, we name it.
What moves between an ERP and a CRM
Before choosing tools, write down each object, which system owns it, which way it flows and how fresh it has to be. For most companies the table looks something like this:
Data | Owned by | Direction | How fresh |
|---|---|---|---|
Account: legal name, tax or VAT number, billing address, payment terms | CRM while it is a prospect, ERP once it is a customer | CRM → ERP at conversion, then ERP → CRM | Minutes |
Account: owner, segment, notes, activities | CRM | Stays in the CRM | n/a |
Contacts | CRM | CRM → ERP, only the ones finance needs (billing, purchasing) | Daily is usually fine |
Products, price lists, discount rules | ERP | ERP → CRM | On change, or nightly |
Stock availability | ERP | Looked up from the CRM when a rep asks | Live |
Sales order | ERP, created from the won deal or accepted quote | CRM → ERP, then status ERP → CRM | Minutes |
Invoices, payments, open balance, credit hold | ERP | ERP → CRM | Hourly or daily |
Quotes are the row teams argue about. If the ERP holds the pricing logic (customer-specific prices, volume breaks, currencies), either build quotes in the ERP or have the CRM ask the ERP for prices. A quote priced in the CRM from a copied price list will drift away from what finance invoices, and the customer notices first.
Start with three flows: customer creation, order creation from a won deal, and invoice and balance status back into the CRM. Add the rest once people are using those.
When you don't need an integration
Three situations where building one usually isn't worth it:
- Your ERP already includes a CRM, or the vendor sells both on a shared data model. NetSuite and Odoo ship CRM modules, and Microsoft connects Dynamics 365 Sales to Dynamics 365 Finance and Supply Chain Management with dual-write, a built-in two-way sync that runs in near real time. Unless sales has a strong reason to want a different CRM, the module you already pay for is cheaper than integrating a second product.
- Volume is low. If sales closes a dozen orders a month, someone rekeying them costs less than building and maintaining a sync. A nightly export and import can cover the gap until volume grows.
- The real request is a report. When management wants pipeline next to revenue, a warehouse that reads both systems can answer that without syncing a single record. Our post on data lakes and data warehouses covers that route.
Decide who owns each field before writing code
Two-way sync of the same field is where integrations go wrong. If both systems let people edit a customer's billing address and the sync uses "last write wins", one side's change silently disappears, and nobody notices until an invoice goes to the old address. Give every shared field one owner. The other system shows it read-only, or sends a change request instead of editing it.
A split that works for most companies: the CRM owns relationship fields (account owner, segment, stage, notes), and once a customer exists, the ERP owns legal and financial fields (legal name, tax number, payment terms, credit limit, billing address).
The handoff from prospect to customer needs its own design, because that is the moment ownership changes hands:
- The prospect exists only in the CRM. The ERP doesn't need to know about it.
- A deal is won. The CRM sends a "create customer" request with the fields finance needs: legal name, tax number, billing address, currency and payment terms.
- The ERP side validates the request (tax number format, possible duplicates, credit check), creates the customer and assigns its customer number. If validation fails, the request lands in a queue that someone in finance owns, with the reason attached.
- The integration writes the ERP customer number into an external ID field on the CRM account, for example a custom
ERP_Customer_Id__cfield in Salesforce. Every later update matches on that number. - The sales order is created in the ERP against that customer. The CRM stores the order number and receives its status changes.
Step 3 is where you find out whether finance and sales mean the same thing by "customer". Have both teams sign off on its rules (which fields are mandatory, what counts as a duplicate, who approves credit) before anyone builds it.
Three ways to build it
Approach | Good fit | Watch out for |
|---|---|---|
Vendor or marketplace connector | Both systems from one vendor, or a common pair with a maintained connector | You inherit its data model and mappings, custom rules are hard to add, and the errors are still yours to handle |
iPaaS or workflow tool (MuleSoft, Boomi, Workato, Celigo; n8n, Make or Zapier at small volumes) | Several systems, standard objects, no in-house integration engineers | Per-task or per-connection pricing grows with volume, and logic spread across visual flows is hard to test and version |
Custom sync service | An on-premises or regional ERP, unusual business rules, high volume | You host, monitor and upgrade it yourself |
For one ERP and one CRM, skip the enterprise service bus. If a maintained connector covers your objects, use it and spend the budget on data cleanup. If it doesn't, a small service with a queue and its own table of ID mappings is cheaper to run and easier to debug than a heavyweight middleware platform. Middleware starts paying for itself as more systems need the same customer and product data.
Two situations change the plan. Many ERPs still run on a server inside the company's network while the CRM is SaaS, so the sync needs a way in: a small agent inside the network that only opens outbound connections, or a VPN. The agent is usually the easier one to get approved by IT. And some ERPs have no usable API at all. Then read from database views or scheduled exports, and write through the import interface the vendor supports, or with a UI bot as a last resort (our RPA guide covers when that is worth it). Don't write straight into the ERP's tables: it skips the ERP's validation, numbering and posting logic, and many vendors won't support data that got in that way.
How the sync works
Noticing changes
There are two ways to find out that something changed. Events push each change as it happens. Salesforce Change Data Capture publishes an event whenever a record on the objects you select is created, updated, deleted or undeleted, and Salesforce recommends its gRPC-based Pub/Sub API over the older CometD Streaming API for subscribing to them. HubSpot offers webhook subscriptions for CRM object changes.
Polling asks "what changed since the last run?" using a last-modified timestamp, and it is often all an ERP supports, especially an on-premises one. Two details matter. Save the watermark (the timestamp you read up to) only after the batch has been written. And overlap each window by a few minutes, because server clocks drift and long transactions commit late. With the overlap some records arrive twice, which is harmless if writes are idempotent. Polling also never sees deletions, so you need a deleted or inactive flag in the source, or a periodic full comparison.
Making writes safe to repeat
Retries will happen, so every write has to be safe to run twice. The simplest way is to upsert on the other system's ID instead of inserting. Salesforce's REST API does this with a PATCH to the external ID: it creates the record when nothing matches, updates it when one record matches, and returns a 300 when several do. A sketch in Python:
import random
import time
from urllib.parse import quote
import requests
BASE = "https://yourcompany.my.salesforce.com/services/data/v67.0" # GET /services/data/ lists your versions
class StopSync(Exception):
"""Expired token or org-wide API limit: stop the run instead of dead-lettering every record."""
def push_customer(session: requests.Session, c: dict) -> None:
"""Create or update the Account for one ERP customer, matched on its ERP number.
The session must send an "Authorization: Bearer <token>" header from your OAuth flow.
"""
url = f"{BASE}/sobjects/Account/ERP_Customer_Id__c/{quote(c['erp_id'], safe='')}"
body = {
"Name": c["legal_name"],
"Tax_Number__c": c["tax_number"],
"Credit_Hold__c": c["credit_hold"],
"Open_Balance__c": c["open_balance"],
}
for attempt in range(5):
try:
r = session.patch(url, json=body, timeout=30)
except (requests.ConnectionError, requests.Timeout):
r = None # network trouble: retry it like a 503
if r is not None:
if r.status_code in (200, 201, 204): # updated or created
return
if r.status_code == 401 or "REQUEST_LIMIT_EXCEEDED" in r.text:
raise StopSync(f"{r.status_code} {r.text[:200]}")
if r.status_code not in (429, 500, 502, 503, 504):
# Validation errors and 300 (several matching records) won't fix themselves.
raise ValueError(f"{c['erp_id']}: {r.status_code} {r.text[:500]}")
time.sleep(min(60, 2**attempt) + random.random()) # back off, then retry
raise RuntimeError(f"{c['erp_id']}: still failing after 5 attempts")Tax_Number__c and the other custom fields are ones you create in Salesforce. The caller catches the ValueError and puts the message in a dead-letter queue, described below. StopSync is a different case: an expired token or a used-up daily API allocation would fail every remaining record the same way, so the run should stop, refresh the token or wait, and continue from where it stopped. Retrying after a timeout, when you can't tell whether the first request went through, is safe only because the upsert is idempotent.
Rate limits and API access
Both sides limit how fast you can go, and the first full load is where you find out. HubSpot allows privately distributed apps 100 requests per 10 seconds on Free and Starter and 190 on Professional and Enterprise, with a daily cap per account of 250,000 on Free and Starter, 625,000 on Professional and 1,000,000 on Enterprise, and every call over the limit gets a 429. The 10-second limit counts each app separately, but all the apps in an account share the daily cap, so your sync competes with every other integration the customer has installed. Salesforce's daily allocation starts at 100,000 requests per rolling 24 hours and grows with the licenses in the org. Use bulk endpoints such as Salesforce Bulk API 2.0 for the initial load, and keep per-record calls for the incremental changes.
Check licensing before the design is final. Professional Edition orgs don't include Salesforce API access by default; it is a paid add-on. Selecting more objects for Change Data Capture than your default allocation also takes an add-on.
When something fails
Sort failures into two groups. Transient ones (timeouts, 429s, a 503 during the other vendor's maintenance window) get retried with exponential backoff and a little random jitter. Data errors (a missing tax number, a payment-terms code the ERP doesn't recognize, a CRM validation rule) give the same answer on every retry, so retrying them only burns API calls. Put them in a dead-letter queue with the payload and the error text, and make clearing that queue a named person's daily job.
Decide early what an outage looks like. If either system is unreachable for an hour, won deals and status changes should wait in a queue and go through when it comes back, not disappear. That means writing each outgoing change to a durable queue or an outbox table first and sending it from there, instead of calling the other system directly from a button click or a trigger. On the CRM account, also show when ERP-owned fields such as credit hold and open balance were last synced, so a rep can tell when the numbers are stale.
Clean the data before you connect anything
An integration copies whatever is already there. If one customer exists under two codes in the ERP and as three accounts in the CRM, the sync will either create a fourth record or send updates to the wrong one. Run a matching pass first: an exact match on tax or VAT number, then normalized legal name plus postcode or email domain, with a person reviewing every fuzzy match. Keep the result as a mapping table (ERP ID, CRM ID, how the two were matched) in the integration's own database, so a merge in either system doesn't break the link.
Don't assume the system of record is clean either. Oplist, a client we build for, receives staff and leave data from private hospitals' HR and payroll systems through live API integrations. Those source systems can contain duplicate records for the same person, and some leave types take precedence over others, so we had to deduplicate and apply a precedence order inside Oplist rather than trust the feed. Oplist also receives the leave type itself (sick leave, an hourly leave, a block leave such as training), because the rostering rules depend on it; "unavailable" alone wouldn't be enough. A blocked account in the ERP works the same way: sync the reason along with the flag (credit hold, legal dispute, business closed), because sales should react differently to each.
Testing and go-live
Load the history first, switch on the incremental sync after, and reconcile before anyone relies on the result. Compare the count of active customers in both systems, and each customer's open balance against the ERP's receivables aging report. When we built a data migration platform for Tribute Technology, its product owner judged success by matching the migrated data against A/R reports, case counts and spot checks. The same three checks work for an ERP-CRM initial load.
Then test the cases that break integrations in production:
- The same message delivered twice. Nothing should be duplicated.
- A customer renamed in the ERP while a rep edits the same account in the CRM.
- Two CRM accounts merged after both were linked to ERP customers.
- A product discontinued while it sits on open quotes.
- A credit hold placed in the middle of a deal.
- Currency and rounding: order totals in both systems should match to the cent.
- A price update touching thousands of products at once, which is where rate limits show up.
Mask personal data before you copy production records into a sandbox to run these.
After go-live, keep two things running: a daily reconciliation job that compares counts and balances and posts the differences where people will see them, and an alert on the size of the dead-letter queue. Agree up front who fixes a broken sync and how fast. For the recurring data work we do for Method Procurement and FrontRunner Professional, our SLA is two days; our post on software support SLAs covers how to set those terms.
What drives cost and timeline
Nobody can estimate an integration well without seeing both systems and a sample of the data, so be wary of a fixed price made without that. These are the things that move the number:
- How many objects, in which direction. One-way invoice status into the CRM is a small job. Two-way customer sync plus order creation is a much bigger one.
- Whether the ERP has a documented API and a sandbox. A cloud ERP with REST endpoints is the easy case. An on-premises ERP reached through an agent, or one that only takes file imports, adds work at every step.
- Data cleanup, which is easy to leave out of an estimate and rarely small.
- Licenses: API access add-ons, Change Data Capture add-ons, HubSpot's API limit increase, and iPaaS task or connection fees.
- Running it afterwards. Both vendors ship releases on their own schedule. Salesforce, for example, retired Platform API versions 21.0 to 30.0 in its Summer '25 release, so integrations still calling them stopped working.
Frequently asked questions
How long does an ERP CRM integration take?
It depends mostly on how many flows you need and what state the data is in, so ask for an estimate per flow (customer, order, invoice status) from someone who has looked at both systems. Configuring a maintained connector between two products from the same vendor is much quicker than a custom two-way sync with order creation. Either way, data cleanup and testing take a large share of the time, and it is worth keeping the old manual process running alongside the sync until the sync has been through at least one month-end close.
Should the sync be real-time or batch?
Minutes for the customer handoff, order status and credit holds, because people act on those during a sale. Polling every few minutes gets you there and is easier to run than event subscriptions, so keep events for the objects where a delay of a few minutes really hurts. Nightly is fine for price lists and history. Stock is better looked up live when a rep asks than copied on a schedule.
Can we do it with Zapier, Make or n8n?
For one-way flows at low volume, yes. Once you need two-way sync, deduplication and reconciliation, you need somewhere to keep ID mappings and failed messages, which pushes you toward a small service or a full iPaaS. If the ERP sits on a server inside your network, n8n has one practical advantage: you can host it yourself, next to the ERP.
If you are planning an integration and want a second opinion on the data model, this is the kind of work our backend and API team does.
Related Articles
Kong vs Traefik vs AWS API Gateway: How to Choose
Kong, Traefik and AWS API Gateway compared as of October 2026: features, licensing, Kubernetes support and what AWS charges for 100 million requests a month.
Read More: Kong vs Traefik vs AWS API Gateway: How to ChoosegRPC vs REST for Microservices: When gRPC Is Worth It
When gRPC beats REST between services, what it adds to your operations (load balancing, deadlines, browser access), and what our own protobuf vs JSON test showed.
Read More: gRPC vs REST for Microservices: When gRPC Is Worth ItRPA Implementation: From Process Choice to Bots That Keep Running
Most of an RPA implementation is choosing the process and designing for exceptions. The order we work in, current license prices, and what broke in the n8n and LLM automation we built with an agency.
Read More: RPA Implementation: From Process Choice to Bots That Keep Running
