I'd never noticed before, but Google Maps does something clever.

Screenshots of US map with distances in miles and NZ maps with distances in kilometres.

I checked a driving distance for a book set in the US and results were in miles. When I checked a New Zealand distance, results were appropriately in kilometres. Good on you Google.