Can I resolve DNS based on country?

Hi,

With cloudflare, can I resolve a domain to different servers based on the incoming IP?
For example, if the user comes from US, resolve to server A, if the user comes from Russia, resolve to server B ?

Thanks

Jeff

Load Balancing with Geo Steering will maintain the hostname, but only goes by regions, not countries:
https://developers.cloudflare.com/load-balancing/understand-basics/traffic-steering#geo-steering

If you want to steer based on countries, you’d have to use different URLs with Workers or Transform:

https://developers.cloudflare.com/workers/examples/country-code-redirect

1 Like