How to connect WordPress forms to HubSpot
You can connect WordPress forms to HubSpot by embedding a HubSpot form, enabling HubSpot’s non-HubSpot form capture, or using a connector that maps submissions directly to CRM fields. The first two methods suit simple forms; use a connector for conditional, multi-step, or custom forms.
- 01Choose the connection method
- 02Embed a HubSpot form
- 03Capture an existing form
- 04Map fields and test records
- 05Use the Forms API for custom workflows
- 06Take the fast connector route
What you need
- A WordPress site with an existing form or page editor
- A HubSpot account with permission to create or edit forms
- WordPress administrator access
- Your form fields and matching HubSpot contact properties
Choose the connection method
Use a native HubSpot form when you are happy to build and manage the form in HubSpot. Create the form in HubSpot, copy its embed code, and place that code in a WordPress Custom HTML block or equivalent page-builder widget. Submissions then go directly to HubSpot.
Keep your existing WordPress form if its design and workflow matter more. HubSpot can capture supported non-HubSpot forms, but this route is less reliable when the form is loaded dynamically, sits inside an iframe, or uses JavaScript that replaces the normal submit event.
Embed a HubSpot form
In HubSpot, open Marketing and then Forms. Create or edit the form, choose the fields you need, and copy its embed code. In WordPress, edit the target page and paste the code into a Custom HTML block, HTML widget, or the equivalent area in your page builder.
Install the HubSpot tracking code on the WordPress site if you need page views, visitor association, or analytics for the embedded form. Add the WordPress domain to HubSpot’s tracking settings as well; submissions from an unregistered domain can be treated as spam.
Capture an existing form
For an existing WordPress form, install the HubSpot tracking code or the official HubSpot WordPress plugin, then enable the non-HubSpot forms setting in HubSpot. HubSpot scans supported HTML forms and sends captured submissions to the CRM after a submission occurs.
This method is fine for a basic contact form, but check the result carefully. The form must use a normal <form> element, cannot be inside an iframe, and may not be detected if it appears after the page has loaded or its JavaScript intercepts submission. HubSpot can also update an existing contact rather than create a second one when the email address already exists.
Map fields and test records
Match each WordPress field to the correct HubSpot contact property. Make the email field required unless you deliberately allow submissions without an email address, because HubSpot normally uses email to create or update the contact record. Use the default HubSpot email property rather than a similarly named custom property unless you have a specific reason not to.
Submit the form with a test address, then check the contact record, submitted values, source information, and any automation that should run. Test both a new email address and an existing contact, because the second test confirms whether your integration updates the intended record.
Use the Forms API for custom workflows
If the existing form cannot be detected and an embedded HubSpot form does not provide the behaviour you need, use a server-side integration with HubSpot’s Forms API. This normally requires developer work to authenticate the site, send the form values, and include the page URL and page name where required.
Do not put a private app token or client secret in browser-side JavaScript. Keep credentials on the server, log failed requests without storing unnecessary personal data, and add a retry or notification process so a temporary HubSpot error does not silently lose a lead. HubSpot identifies missing page information and tracking code as common causes of submission-record errors.
Take the fast connector route
For conditional or multi-step WordPress forms, use JetFormBuilder HubSpot rather than relying on automatic detection. Install and activate the form builder and HubSpot add-on, then open JetFormBuilder > Settings > HubSpot API and use the OAuth 2.0 connection for a new setup. The add-on also documents a legacy API-key option, but its current guidance recommends OAuth 2.0 for new connections.
Edit the form, add the HubSpot post-submit action, connect the account, and map the email, name, phone, company, owner, lifecycle stage, and any custom properties. This is the quicker choice when lead capture needs conditional logic, multi-step forms, or deliberate field mapping instead of basic submission capture. Submit several test records before publishing the form.
Let JetFormBuilder HubSpot do it
Direct HubSpot syncing with conditional and multi-step forms; choose it when lead capture needs more than basic form submissions.
Sources
- knowledge.hubspot.com /forms/set-up-and-style-your-form-on-an-external-site?pix=5y…
- knowledge.hubspot.com /forms/non-hubspot-forms-faq?k=EAIaIQobChMIv-DY8f-b9QIVSOvjB…
- knowledge.hubspot.com /reports/install-the-hubspot-tracking-code?mainArticle=true…
- knowledge.hubspot.com /forms/troubleshoot-hubspot-forms?Sid=1&utm_source=openai
- jetformbuilder.com /addons/hubspot/?utm_source=openai
Questions
- Can I connect a WordPress form to HubSpot without another form plugin?
- Yes, but only for suitable forms. You can embed a form created in HubSpot, or enable HubSpot’s non-HubSpot form capture for a compatible HTML form. The second option depends on the tracking code, normal form markup, and a submit event HubSpot can detect. If your form uses an iframe, AJAX replacement, or complex custom behaviour, use a direct connector or the Forms API instead.
- Why is my WordPress form submission not appearing in HubSpot?
- The usual causes are missing tracking code, an unregistered site domain, an iframe, JavaScript that prevents HubSpot seeing the submit event, or a form added after the page finished loading. First test the page in a clean browser, confirm the tracking code is present once, check the domain settings, and submit a form with a valid email address.
- Will HubSpot create a new contact for every form submission?
- No. HubSpot normally uses the submitted email address to identify contacts, so a submission from an existing email address can update that contact instead of creating a duplicate. Tracking cookies can also associate activity with an existing contact. Test both new and existing email addresses before enabling follow-up workflows.
- Should I embed a HubSpot form or connect my existing WordPress form?
- Embed a HubSpot form when you want the simplest supported setup and are comfortable managing the form in HubSpot. Connect the existing WordPress form when its layout, conditional logic, multi-step flow, or other WordPress features are important. For anything beyond a basic form, deliberate field mapping through a connector is safer than relying on automatic non-HubSpot form detection.
- Do I need a plugin to use the HubSpot Forms API?
- You do not need a WordPress plugin, but you do need custom development or an integration service. A developer must authenticate requests, send the submitted properties to HubSpot, handle errors, and protect credentials on the server. A connector plugin is usually faster when your form already needs conditional logic, multi-step screens, or custom field mapping.