Skip to main content

How to Set a Primary Company in HubSpot with a CSV Import

Nothing uploadedTested up to 10 MB

Build a HubSpot contact-to-company association CSV, mark the relationship Primary, and keep unmatched or ambiguous rows out of the import.

Published: 2026-09-24Updated: 2026-09-242 minBuild the HubSpot association CSV
Data workflow illustration for How to Set a Primary Company in HubSpot with a CSV Import

HubSpot can import associations between Contacts and Companies through its advanced import flow. The important detail for a primary relationship is the association label: the association row should be mapped with the value Primary.

That is different from filling a Contact property such as Company name. A property value can be useful for matching, but the relationship itself must be imported as a Contact–Company association.

What to put in the association CSV

A practical association file needs three pieces of information:

| Column | Purpose | | --- | --- | | Contact identifier | Identifies the Contact, for example Email, Record ID, or another unique property | | Company identifier | Identifies the Company, for example Company domain name, Record ID, or another unique property | | Association label | Use Primary for the company that should become the Contact's primary company |

Keep the original identifiers exactly as they appear in the HubSpot exports. Do not translate the value Primary in the prepared output.

A safer preparation workflow

  1. Export the Contacts and Companies you need from HubSpot.
  2. Choose how the two exports should match: email domain to company domain, company name to company name, or a shared custom/record ID.
  3. Review duplicate company keys before creating the import. One match key should resolve to one company.
  4. Build the association CSV and exclude rows that are unmatched or ambiguous.
  5. In HubSpot, use the advanced import flow and map the two object identifiers plus the association label.

The Nablyx builder performs the matching in the browser and exports only confirmed pairs with Association label=Primary. It does not connect to HubSpot or require an API token.

Which identifier should you use?

Email-domain matching is convenient when business email domains line up with Company domain name. Company-name matching can work for clean exports, but duplicate or renamed companies make it less reliable. Record IDs or a custom property configured as unique are the strongest choice when the same key is available on both sides.

If the company export contains the same domain, name, or custom key more than once, resolve the duplicate first. Picking the first match silently can attach a Contact to the wrong Company.

Import it in HubSpot

Use HubSpot's advanced import workflow rather than the quick contact importer when you need associations. Select Contacts and Companies as the objects involved, map the Contact identifier, map the Company identifier, and map the association-label column so the value Primary is interpreted as the primary company relationship.

HubSpot documents the import-file requirements in its import file setup guide and explains record associations in its association guide.

Review before importing

Open the generated CSV and spot-check several rows against HubSpot. Pay particular attention to shared domains, common company names, subsidiaries, and contacts using personal email domains. Those are the cases most likely to need a manual decision.

Build a Primary Company CSV

See the transformation

Two tables meet on one exact lookup key.

Add matching customer details to each order while keeping missing or repeated matches visible.

orders.csv · customer_id
orderkeyamount
1001C-4284.50
1002C-9142.75
customers.csv · id
keynametier
C-42Aminapro
C-42AminaVIP
Result
orderkeynametier
1001C-42Aminapro
1002C-91——