How does the WPEngine GeoIP service work?

Today WPEngine launched their new GeoIP service, and I was excited to check it out. After doing a presentation on handling Geolocation in WordPress I know it can be a difficult problem to solve at scale, especially with any kind of caching.

The way it works is by having a plugin installed that gives you functions to grab the city, country, and region:

$geo = WPEngine\GeoIp::instance();
echo "Welcome from {$geo->city()}, {$geo->region()}, {$geo->country()}!";

With access to the location in this format, you can start to show specific content or features depending on where the visitor is from.  Someone coming into your store from England?  Show them £ instead of $.  What about Japan?  Default the language to Japanese without asking them.  WPEngine will detect that you’re serving different content for different users, and cache in ‘buckets’ without you having to configure anything.

The service does require a Business level plan or higher, but chances are if you’re serving multiple countries you’d be at that level anyway.

You can view the full FAQ on the new feature.