A very common need in HubSpot is to automatically associate a contact with an existing company based on their email domain (e.g., associating joe@example.com with the "example.com" company record).
This "dynamic company search and association" is difficult to achieve with standard functions alone. This is where 3rd-party custom workflow actions become essential.
This article explains the purpose, use cases, and setup steps for the "Company Search Action" shown in your video.


The primary purpose of this action is to search your HubSpot database for a "Company" record that matches specific criteria—often based on information from the contact enrolled in the workflow (Contact A).
The action's only output is the Record ID (Company ID) of the company it finds. The ultimate goal is to use this ID to automatically associate the enrolled contact with that company.
This action is invaluable for automating the organization and linking of your contacts and companies.
sato@example.com, the workflow uses their "Email Domain" property (example.com) as a search key. It finds the Company (Company B) that has example.com as its "Company Domain Name" and automatically associates Contact A with Company B. (This is the exact use case shown in the demo).The video demonstrates the setup and execution of the "Company Search Action."
Step 1: Add the Action (0:04 - 0:09)In the workflow editor, click the "+" icon. The left sidebar opens, showing available custom actions. The video selects the app "Custom Workflow Business V2."
Step 2: Select "Company Search Action" (0:10 - 0:12)From the app's list of actions, click "Company Search Action" to add it to the workflow.
Step 3: Configure Search Criteria (0:13 - 0:39)In the action's setup panel on the left, you define which company you are looking for.
Condition - Property Name (e.g., Company Domain Name), the Condition - Search Operator (e.g., Equal to), and the Condition - Value (e.g., "sweetsvillage.com").(In a real-world scenario, you would typically use a personalization token here, such as the enrolled contact's "Email Domain" property, instead of a static value.)Company name). You can use the Operator between Conditions to set the logic to "AND" or "OR."Step 4: Save Configuration (0:40 - 0:42)Click the "Save" button. The workflow card updates to show a summary of your criteria.
Step 5: Run Workflow & Check History (0:43 - 0:52)The workflow is turned on and run. Afterward, check the "History" tab. You can see the "Company Search Action" has "Action succeeded."The log details (right panel) show the "OUTPUTS," confirming that search_results has successfully returned the Company Record ID (e.g., "19578297576").
Step 6: Verify the Result (0:53 - 0:56)(As a supplement to the demo) You can then go to your HubSpot Company list and confirm that the company with ID "19578297576" is indeed the "test" company with the domain "sweetsvillage.com."
This action only finds the Company ID. To complete the goal, you must combine it with a standard HubSpot action.
search_results) "is known". This ensures the next step only runs if a company was successfully found.[search_results] output.This completes the automation. When a contact enrolls, the workflow searches for a matching company, and if one is found, it sets the contact's "Company ID" property to that company's ID, automatically associating them.
No, it is not. This is a custom action that becomes available by installing a third-party app called "Custom Workflow Business V2." While you can associate a contact with a company using standard features (e.g., by updating the "Company ID" property), this action is different because it allows you to perform a dynamic search as a workflow step, such as matching a contact's "Email Domain" with a company's "Company Domain Name."
No, it does not. As emphasized in the article's "【Important】How to Associate the Contact with the Retrieved Company ID" section, this action's only job is to search for and find the Record ID of the matching company. To actually associate the contact with the company, you must add HubSpot's standard "Set property value" action after this custom action. In that action, you must set the enrolled contact's "Company ID" property to the output (search_results) from this search action.
Yes, you can. That is the most common use case for this action, as explained in the "Main Use Cases" section. Instead of entering a fixed value (sweetsvillage.com) in the search criteria (Condition - Value) in Step 3, you would set a property token from the contact enrolled in the workflow (e.g., [Email Domain]). This allows you to perform a dynamic search, such as "find Company B that matches Contact A's domain."
We can customize this sample to match your specific business requirements.
Book Free Consultation