> For the complete documentation index, see [llms.txt](https://support.goodaccess.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://support.goodaccess.com/configuration-guides/ip-whitelisting/nginx/domain.md).

# Domain

## Whitelist IP in NGINX for a domain

Add the above lines in any of the *http*, *server* or *location* / blocks as shown below

```
http{
   ...
   allow 45.43.23.21;
   deny all;
   ...
}

server{
    ...
    allow 45.43.23.21;
    deny all;
    ...
}


location / {
   allow 45.43.23.21;
   deny all;
}
```

## Restart NGINX

Run the following command to check the syntax of your updated config file.

```
sudo nginx -t
```

If there are no errors, run the following command to restart the NGINX server.

```
sudo systemctl restart nginx
```
