> For the complete documentation index, see [llms.txt](https://docs.dingdoong.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.dingdoong.io/local-delivery/delivery-validator/maximum-distance-radius.md).

# Maximum Distance Radius

## Maximum Radius Method&#x20;

The maximum radius method checks if the customer's location is eligible for delivery by checking the address that he put in the widget. That address will need to be within the radius you specified in your delivery condition settings.

{% hint style="success" %}
To use this feature, you need a **Distance Matrix API key**
{% endhint %}

<mark style="background-color:purple;">How to get the API key:</mark>

**Step 1: Choose or create a new project**

1. Go to the [Google Cloud Console](https://console.cloud.google.com/home/dashboard)
2. Click the project drop-down and select or create the project for which you want to add an API key&#x20;

**Step 2: Create an API key**

1. Click the menu button and select Google Maps Platform > Credentials
2. On the Credentials page, click + Create Credentials > API key&#x20;

**Step 3: Enable Distance Matrix API**

1. Click the menu button and select APIs
2. On the APIs page, choose Distance Matrix API and enable it

{% embed url="<https://www.youtube.com/watch?v=oVoHv7EQvGs>" %}

{% hint style="success" %}
You have to own a paid Google Cloud Project to be able to get a valid API key.
{% endhint %}

{% hint style="success" %}
You can use the same API key and enable **Places API** if you also use Store pickup function and want to show your store location on the map.
{% endhint %}

## How Does The Maximum Radius Method Work?

You will need to **enter your key location** and **pick the maximum radius** approved to deliver in the delivery conditions setting

<figure><img src="https://825397875-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fdt3xbyFDcRxJKS1ZARtZ%2Fuploads%2FIUDiWKIEG19IlCgtqSd4%2FFrame%205054.png?alt=media&amp;token=597a91dc-ab1d-4365-9ee1-83413d33475c" alt=""><figcaption></figcaption></figure>

Your customers will need to enter their address in the widget to check if delivery is available

![](https://825397875-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fdt3xbyFDcRxJKS1ZARtZ%2Fuploads%2FeivJJMMg5ixo0D93zWCK%2Fimage.png?alt=media\&token=859e8732-3630-4996-b290-b0a4c68c6e9f)

If the address that the customer entered in the widget falls within the radius you specified in your delivery condition settings, he will be able to proceed

![](https://825397875-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fdt3xbyFDcRxJKS1ZARtZ%2Fuploads%2FleHaTCiYRHL0VdUA3wmC%2Fimage.png?alt=media\&token=2ce2cf5b-0a89-4a7d-8a92-74b6fca8a807)

If the address that the customer entered in the widget is out of the radius you specified in your delivery condition settings, he will be unable to proceed further

![](https://825397875-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fdt3xbyFDcRxJKS1ZARtZ%2Fuploads%2FdpG9uHG4RGfF9LQMkyvb%2Fimage.png?alt=media\&token=36123e96-ea5d-4070-ac7b-741ed290f1e2)

## How To Enable The Maximum Radius Method?

**Step 1**: At the DELIVERY LOCATION VALIDATOR section, tick to choose **Maximum radius**&#x20;

**Step 2**: Enter your valid [Google API key](broken://pages/ifeJczqcfn8QrgmkoMNA)

**Step 3**: Type your key location to set the radius for

**Step 4**: Pick the country for your key location

**Step 5**: Pick the state/city for your key location

**Step 6**: Decide to check radius restriction by **km** or **mile** and then pick the maximum radius that you allow to deliver

**Step 7**: Click the **Save** button

<mark style="background-color:purple;">\*Note:</mark>&#x20;

All of the fields must be filled in to have the method make sense. Therefore, kindly complete all fields without omitting any of them

<figure><img src="https://825397875-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fdt3xbyFDcRxJKS1ZARtZ%2Fuploads%2FU7QwK1FIJJ7e3jwidv1j%2FFrame%205054%20(1).png?alt=media&amp;token=69d14875-dfe9-4e02-a56d-a6f33048b6ce" alt=""><figcaption></figcaption></figure>

{% hint style="success" %}
Reach out to us via the email [**contact@omegatheme.com**](mailto:contact@omegatheme.com) if you stumble upon something hard to solv&#x65;**.** Any messages from you are greatly appreciated!
{% endhint %}
