Create or select a form
From your HubSpot Marketing dashboard, navigate to Contacts > Forms and either open an existing form or create a new form.
Edit your dependent fields
Once in your form, hover your mouse over the field you want to add dependencies to and click Edit.
In the Configuration window on the left, you'll be presented with different settings for your form field. Scroll down to the bottom and click Dependent field to expand this option. In the example below, we're setting up dependent fields for the country field, so it starts with "If Country."
2. This area is where you'll want to place the value that the visitor will enter into the form. So when you ask what country they're from, this is looking for anyone who says "United States."
3. This dropdown decides which field to show depending on the criteria you've set from the previous steps. So, in this example, if the visitor selects "United States" as their Country, it will then show the State/Region field for them to also fill out.
When you're done, click Add to confirm the new dependent form field.
You can add another rule if you want to build out more dependencies for this particular field.
View your dependent form fields
After you set up your dependent form fields, you'll see that the dependent field connected to the field that it is dependent on with a dotted line. In the example below, you can see State/Region tied to Country and that State/Region will only show if Country is equal to United States. You can click Close dependent field options to hide the dependent field(s) while you're viewing and editing your form.
Save your form
Click Save when you're done.
Test your form
At the top, click Test to see an interactive preview of the way your form will look on a live page.