Google Maps API Distance Matrix Explained

Distance Matrix API calculates travel distance and duration (time) between two or more locations based on transportation modes such as driving, walking