> For the complete documentation index, see [llms.txt](https://software-help-docs.gitbook.io/knowledge-base/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://software-help-docs.gitbook.io/knowledge-base/software-guide/forms/understanding-automatic-country-detection-in-forms.md).

# Understanding Automatic Country Detection in Forms

Automatic country code detection is a great feature in forms. Forms are smart enough to recognize the location of the person that has accessed the page. The only action on your end is to ensure you're using a phone field in a form for this to apply.

**Step 1: Using the Phone Field**

* Navigate to the Form Builder.
* Create a new form or edit an existing form.

{% embed url="<https://lh3.googleusercontent.com/q2FneWkNFX1EYn4YISKKWQ8sqVJgs6oyownSB65zXe4fq1a0mwYry9v3opVzBhduQyWhfd4W1mexcyMWk3NgLgS476yqQEQMqvJz25y_FnoRuSwQTHuWrR6Lv1eKErYP6y6AXYU=s0>" %}

* Utilizing the Standard Fields on the right-hand side, drag and drop the Phone field into the form.
* Save the form.
* Integrate the form.

**Step 2: Viewing the Automatic Country Code Detection**

* Copy the link and visit the Form in a new browser tab.

You'll see the phone field has a country flag next to it. That flag should be the country you're physically located in, as the person accessing the form. (In the video and screenshot examples, it is the USA.)

{% embed url="<https://lh4.googleusercontent.com/_tCb8KwWdZIaEQRTnCmX7ZK4hi238tqSf3QIuB_Zp_ZlwXtH6ZxmNS0JgoJwKeKjlki9kAGbMrOXm0RUyUrDOo0C9_EeFVN-7739nZrLuPWLnEcGmcTFZPT7FGWgH3IiINFWPYE=s0>" %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://software-help-docs.gitbook.io/knowledge-base/software-guide/forms/understanding-automatic-country-detection-in-forms.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `build a script that syncs our docs to a CMS` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
