Skip to main content
Default matches Salesforce leads to accounts inside a workflow. A Match Record node searches your Salesforce Accounts for the lead’s company, usually by comparing each Account’s Website with the domain of the lead’s email, then follows its Match or No Match branch. Later nodes use the matched Account to route the lead to the account owner, show the owner’s calendar, or merge the lead into that Account with Convert Lead. Matching is built from workflow nodes, so each rule can be tested and each decision shows in the run logs. The nodes are documented in CRM nodes. For a signal that names a company but no person, such as a website visit, see Salesforce account and HubSpot company matching.

How lead-to-account matching works in Default

A lead-to-account workflow in Default runs these steps:
  1. A trigger starts the run with the lead. Use CRM Record Created on the Salesforce Lead for leads that already exist in Salesforce, or Form Submission, API, or Incoming Webhook for leads that arrive with form or request data. See Triggers.
  2. Match Record searches Accounts. Set Record to Account. The conditions under Match Details decide which Accounts count as the lead’s company.
  3. Tiebreakers pick 1 Account. When several Accounts match, the rules under Prioritize matched records by choose 1 of them.
  4. The node branches. Match carries the chosen Account’s ID and fields to later nodes. No Match runs when no Account qualifies.
  5. Later nodes act on the result. On Match, route the lead to the account owner or convert it into the Account. On No Match, route the lead through a queue.

Match options for Salesforce accounts

Match Details compares Account fields with values from the trigger or earlier nodes. It lists the Account fields that Salesforce lets you filter on, including custom fields. Combine conditions with and or or. Match Details needs at least 1 condition before the workflow can be published.
Use domain matches instead of contains string on Website. contains string compares raw text, so hp.com also matches companyhp.com, and a lead from eu.hp.com misses a website stored as https://www.hp.com.

When several Salesforce accounts match

A company often has several Accounts, for example a parent and its subsidiaries, or duplicates created by different teams. Prioritize matched records by decides which one the workflow uses. It is optional. Select Add tiebreaker to add a rule: How Default applies the rules:
  • Only when 2 or more Accounts match. When exactly 1 Account matches, the node uses it and runs no rule. Put a hard requirement, such as the Account owner, in Match Details instead.
  • In order, top to bottom. Drag a rule to reorder it. A sort rule directly below another sort rule breaks its ties. Empty values sort last.
  • Filter rules narrow the list but never empty it. Has a parent account and Prefer records where… keep only the Accounts that meet them. When none of the remaining Accounts meets a filter rule, Default skips that rule, keeps the Accounts for the next rules, and adds a warning to the run log. Tiebreakers never send the node to No Match.
  • Without rules, the first result wins. Default takes the first Account Salesforce returns, and that order is not defined. Add at least 1 rule whenever more than 1 Account can match.
  • Rules see a limited window. When Default sorts or filters the matches itself, it reads a limited number of matching Accounts. If that limit is reached, the run log shows a warning with the query limit, and better matches beyond it are skipped. Narrow Match Details so fewer Accounts match.
For example, add Largest by employees and then Most recently modified. The lead goes to the largest Account for its domain, and the most recently updated Account wins a tie. To send leads only to Accounts owned by a current rep, add Owner ID equals a queue of your account executives to Match Details, joined to the Website condition with and. Accounts owned by anyone else never match, so those leads follow No Match and go to round robin.

When no Salesforce account matches

The node follows No Match in these cases: Give No Match its own path. Route the lead through a queue with a Round-Robin node, send it to an enrichment node to find the company first, or both.

Build a Salesforce lead-to-account workflow

This example sends each new inbound Salesforce Lead to the owner of its company’s Account. Leads without a matching Account go to the next member of a queue named Inbound Leads.
1

Add the trigger

In Workflows, create a workflow and add the CRM Record Created trigger. Set CRM to Salesforce and Record to Lead. Optionally, add a Condition, for example Lead Source is Inbound.
2

Add Match Record for the Account

Select Add Node and choose Match Record from the Records section. Set CRM to Salesforce and Record to Account.Under Match Details, select Edit. Choose Website as the field and domain matches as the operator. For the value, pick the Lead’s Email from the trigger and choose Domain from email. Select Save changes.
3

Add tiebreakers

Under Prioritize matched records by, select Add tiebreaker and choose Largest by employees. Add a second tiebreaker, Most recently modified.
4

Route matched leads to the account owner

On the Match branch, add Update Record. Set Platform to Salesforce and Record Type to Lead. For Record to update, choose the Lead’s record ID from the trigger.Under Fields, add Owner ID. For its value, open the data picker and choose the Account’s Owner ID from the Match Record step.
5

Round-robin the rest

On the No Match branch, add Round-Robin from the Actions section and set Queue to Inbound Leads. Then add Update Record for the Lead and set Owner ID to Latest assigned user under Round robin.
6

Test and publish

Select Test, choose the trigger, and fill in a sample Lead whose email domain belongs to an existing Account. Select Run Test and check the Lead owner in Salesforce. Then select Publish and check that the status next to the deployment switch reads Live. A new workflow goes live when you first publish it. If the status reads Paused, turn the switch on.
A workflow test performs real actions in Salesforce. Use a test Lead.
An owner copied from the Account does not count toward any queue’s round robin. Only an owner that comes from a Round-Robin node counts as a queue assignment. For a lead that arrives from a form, check for an existing Lead or Contact first, so a repeat form fill does not create a duplicate. See Salesforce contact matching. To book the lead with the account owner, add Display Scheduler on the Match branch. Turn off Use event hosts and add the Account’s Owner ID from the Match Record step as the host. The owner needs a Salesforce mapping in Settings → Users so Default can find their calendar. See Routing and scheduling nodes.

Convert a matched lead into the existing account

Convert Lead turns a Salesforce Lead into a Contact under an Account. Set Account to merge into (optional) to the matched Account, and Salesforce adds the new Contact to that Account instead of creating a second Account for the same company. Add Convert Lead after the Match branch of the Account Match Record node: What to know before you convert:
  • Salesforce only. Convert Lead works on Salesforce Leads and has no HubSpot version.
  • Converted status. Default uses the first converted lead status in your Salesforce organization, by sort order.
  • Already converted. If the Lead is already converted, the node returns its existing Account, Contact, and Opportunity IDs and continues without converting again.
  • Outputs. Later nodes can use the Lead, Account, Contact, and Opportunity IDs.
  • Author Apex. Default converts leads through Apex, so the Salesforce user connected to Default needs the Author Apex permission.
  • Duplicate rules apply. A duplicate rule set to block stops the conversion, and the node fails. A rule set to allow with an alert lets it through.
  • Permanent. Salesforce cannot undo a lead conversion. Test with a test Lead.

Check a Salesforce lead-to-account match

Open the workflow, select Runs at the top, and select a run. In the run details, the Match Record step shows its conditions, how many Accounts Salesforce returned, and the Account it chose. When domain matches dropped a lookalike domain, the step also shows how many candidates survived. See Run logs.

Troubleshoot Salesforce lead-to-account matching

Related: Lead routing software from Default