In case you use some GeoIP modules (like our Magento 2 Language and Currency Switcher Extensions) and have the Varnish installed, then you need to make some additional configurations for it.

The simplest configuration is to add the following lines to the varnish config file:

if (req.http.cookie !~ "PHPSESSID=" && req.http.User-Agent !~ "bot" && req.http.User-Agent !~ "loader") {
return (pass);
}

In this case, the first customer visit will not be cached by varnish, the php Magento will generate the right cookies, switch to the right store view and change the currency.

However, the drawback of this approach is that the store view will be displayed without varnish cache during the first visit. If you want to avoid this you can configure the varnish cache to have different caches for different countries

To achieve that you have to configure the GeoIP with Varnish. Follow this link for step-by-step instructions.