Create dynamic forms with conditional logic

Forms shouldn't be one-size-fits-all. Use conditional logic to create a personalized experience for your responders.

Build your formWant to know if Formsort is right for you? Get in Touch

Companies building smart forms on Formsort

FormHealth - Formsort healthcare formCandid - Formsort hippa compliant formVial - Formsort hipaa compliant formAllara - Formsort hipaa compliant formGoodRx - Formsort hipaa compliant form

Adding conditional logic to forms

Whether you need to collect clarifying details, adjust choices dynamically, or create personalized paths based on user input, Formsort provides the flexibility to improve the experience and gather precise data.

Conditional question

Use case: When a respondent answers "Other" to a question.

Application: Automatically show an input field to gather additional information or specification.

Dynamic choices

Use case: Choices within a select question that depend on previous responses.

Application: Display or hide specific options based on the responder's earlier selections, ensuring relevance and clarity.

Step-level logic

Use case: Applying logic to an entire step or page in the form.

Application: Show or hide a group of questions based on specific logic. This is useful when the same logic applies uniformly to all questions within a step.

Group-level logic

Use case: Grouping questions based on certain criteria (e.g., gender).

Application: Show or hide an entire group of steps relevant to a specific category.

Conditional redirects

Use case: Redirect based on responses or conditions met during the form.

Application: Conditionally redirect responders to specific URLs based on their answers. This ensures that the responders end up in the relevant paths.

Conditional calculated variables

Use case: Decide when to calculate a variable based on conditions.

Application: Dynamically calculate variables in real-time based on specific conditions met during the form-filling process, allowing for accurate and context-specific data.

Form logic - from basic to complex

Simple logic

Simple logic allows you to render or hide a question based on the user's earlier responses in the flow. It supports multi-clause conditions and enables nested logic through grouping.

Advanced logic

For complex scenarios you can use advanced logic to define arbitrary boolean expressions over the answers by utilizing MongoDB query and projection operators.

Calculated variables

When your logic requirements extend beyond simple logic, calculated variables come into play. Leverage JavaScript (Typescript format) functions to create variables dynamically.

API variables

Leverage API variables to create logic for conditionally rendering steps with external data. You can then use the data to create logic to conditionally show / hide elements in the form.

Form template examples with conditional logic

Quickly launch forms for personalized responder journey using our ready-to-use templates.

See all templates

Build dynamic forms with Formsort

Partially completed forms

Get partial form responses and re-engage leads who gave up halfway through

Custom validation

Validate responder data with custom validators, and provide custom error messages

Authenticated forms

Limit access to your forms to authenticated users

Custom design

Create forms that match your brand and website design

Returning responders

Allow users to return to a form and continue from the furthest point

External (hidden) fields

Pass data into your forms and pre-fill fields from external sources, including UTM params

HIPAA-compliant form builder

Collect sensitive medical information securely