> ## Knowledge Base Index
> Fetch the complete knowledge base index at: https://help.spreadly.app/sitemap.xml
> Use this file to discover available pages before exploring further.
> Pure-Markdown content can be obtained by appending a '.md' suffix to the content URLs listed in the sitemap (without the trailing slash).

# Conditional Lead Form Fields

Hey there! In this article, we’ll show you how to set up conditional form fields in Spreadly, so your forms only ask for what’s *actually* needed.

Let’s walk through a classic example: You want a user to enter a **phone number only if they don’t provide an email**. If they type in their email, the phone field disappears (and isn’t required anymore). Magic, right?

| See [Add Fields to a Lead Form](https://help.spreadly.app/en/article/add-fields-to-a-lead-form-8lc3yz/) on how to add Fields to a Lead Form.

|| Only Lead Forms with at least one required field are automatically shown in the Spreadly app

## 1. Basic Setup: Add Your Fields

Start by dragging your fields into the form. Here’s what it looks like at first:

![Lead Form Fields](https://storage.crisp.chat/users/helpdesk/website/-/6/1/b/6/61b64ab3334f9c0/screenshot-17112025-um-152736-_1sewfk7.png =706xauto)

* **Name** field is always required.
* **Email** and **Phone** are added, but not required yet.



## 2. Add Conditional Logic to “Phone” Field

Now, let’s make the **Phone** field only show when *Email is empty*.

* Click on the “Show, if” dropdown next to the Phone field.
* Select **Email** so we’re basing the condition on the Email field.

Check out the menu of conditions you get:

![Condition Options](https://storage.crisp.chat/users/helpdesk/website/-/6/1/b/6/61b64ab3334f9c0/screenshot-17112025-um-152759-_1h0k35f.png =667xauto)

* Choose **Empty** (no need to enter a value!)



## 3. Make the Phone Field Required (Only When Shown)

Turn on the “Required” switch for the Phone field. This means:
* If the phone field is visible, it *must* be filled out.  
* If it’s hidden (because the user gave an email), it’s *not* required.

Here’s how the final setup looks:

![Phone Required is only shown and required when no email is provided](https://storage.crisp.chat/users/helpdesk/website/-/6/1/b/6/61b64ab3334f9c0/screenshot-17112025-um-152833-_1dtn77n.png =687xauto)

* **Name:** Always required.
* **Email:** Shown (but not required here).
* **Phone:** Only shown & required if Email is empty.


## What Does This Mean for Your Users?

* If the user enters an email, they won’t see the phone field at all.
* If they leave email blank, they *must* enter a phone number to submit the form.

|| “Empty” and “Not Empty” conditions don’t require you to enter any value.  