> ## Documentation Index
> Fetch the complete documentation index at: https://filla.io/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Phone number field

> Phone input with country selector, format validation, and auto-detect.

## What this does

The phone number field maps to Airtable's Phone Number field type. It includes a country code selector, automatic country detection, and format validation against country-specific phone number patterns.

## Settings reference

| Setting                   | Description                                                                                                                                  |
| ------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------- |
| **Placeholder text**      | Hint text shown when the field is empty.                                                                                                     |
| **Default value**         | Phone number pre-filled when the form loads.                                                                                                 |
| **Default country**       | The country code pre-selected in the country dropdown. Enter a 2-letter country code (e.g., `US`, `GB`, `AU`, `CA`, `NG`).                   |
| **Show country selector** | Display a country code dropdown before the phone input so respondents can select their country's dial code.                                  |
| **Validate phone format** | Validate that the number matches the expected format for the selected country. Shows an error with an example number if the format is wrong. |
| **Auto-detect country**   | Pre-select the respondent's country based on their IP-derived location. Respondents can still change it manually.                            |
| **Minimum characters**    | Minimum character count required.                                                                                                            |
| **Maximum characters**    | Maximum character count allowed.                                                                                                             |

**Universal settings that also apply:** Label, description, required, read-only, show/hide rules, conditional read-only, reject duplicates, custom validation rules.

## The country selector

When **Show country selector** is enabled, the phone field displays a flag-based country selector next to the phone input. Each country shows its circular flag icon and dial code (e.g., +1, +44, +234).

The selector includes a **search field** at the top so respondents can quickly find their country by typing the country name. The full list of 240+ countries is searchable and scrollable.

The country selector respects your form's theme — colors, fonts, and border styles match the rest of the form.

## How country detection works

When **Auto-detect country** is enabled, Filla uses the respondent's IP address to determine their likely country and pre-selects the matching dial code in the country selector. The respondent can override this by selecting a different country from the dropdown.

<Tip>
  Enable both **Show country selector** and **Auto-detect country** together for forms that accept international respondents. The right country code is pre-selected, but respondents from other countries can change it.
</Tip>

## Format validation

When **Validate phone format** is enabled, Filla checks the entered number against the expected format for the selected country (powered by libphonenumber). If the format is wrong, the error message includes an example of a valid number for that country.

**Example:** For the US, a valid format is `(555) 555-5555`. For the UK, `07700 900000`. The validator checks these formats on blur (when the respondent leaves the field).

## Common questions

<AccordionGroup>
  <Accordion title="Can I require a specific country's format?">
    Set the **Default country** and optionally hide the country selector by turning off **Show country selector**. With a fixed country selected and format validation on, only numbers in that country's format will be accepted.
  </Accordion>

  <Accordion title="How is the phone number stored in Airtable?">
    The number is stored as entered, including the country dial code if the country selector is shown. For example: `+1 555-555-5555`.
  </Accordion>

  <Accordion title="Does format validation block submission?">
    Yes. If format validation is enabled and the number doesn't match the expected pattern, the respondent sees an error and cannot submit until the number is corrected or the country is changed.
  </Accordion>
</AccordionGroup>
