Distance Guide

Distance Between Two Locations Explained

The distance between two locations depends on how you measure it. Two places can have one straight-line distance, a longer driving distance, and a different walking or travel distance because each method follows a different path.

If you know the latitude and longitude of both locations and want their direct geographic separation, use our Distance Calculator. If you need road mileage instead, use the Driving Distance Calculator.

What Does Distance Between Two Locations Mean?

Distance between two locations describes how far one geographic place is from another.

A location may be:

  • a city;
  • a town;
  • an address;
  • an airport;
  • a landmark;
  • a GPS coordinate;
  • a point selected on a map.

The important question is not only which two places you are comparing, but also which type of distance you need.

For example, the distance between New York City and Boston can be measured as:

  • direct geographic distance;
  • driving distance;
  • walking-route distance;
  • flight distance;
  • map distance between selected points.

These values do not have to be the same because they measure different paths.

What Are the Main Ways to Measure Distance Between Two Locations?

There are four common ways to describe distance between geographic locations.

Straight-Line Distance

Straight-line geographic distance measures the shortest surface path between two locations without following roads.

For places represented by latitude and longitude, this is commonly calculated as a great-circle distance.

Our Distance Calculator uses this method for two coordinate pairs.

Driving Distance

Driving distance follows the available road network between the starting location and destination.

It can be affected by:

  • road layout;
  • highways;
  • bridges;
  • tunnels;
  • restricted routes;
  • borders;
  • available connections.

Use the Driving Distance Calculator when you need road mileage rather than direct geographic separation.

Map Distance

Map distance can refer to the direct distance between points selected visually on a map.

Our Map Distance Calculator lets you click two locations and calculates the direct geographic distance between those selected coordinates.

Walking or Route Distance

Walking distance follows routes that are available to pedestrians rather than simply measuring the geographic separation between the points.

A walking route may differ from both straight-line distance and driving distance because pedestrian access does not always follow the same road network as a car.

See our Walking Route Distance Calculator guide for that specific use case.

What Is the Difference Between Distance Between Places and Driving Distance?

Distance between places is a broad concept. Driving distance is one specific type of distance between locations.

Suppose two locations have a straight-line distance of 10 miles.

A road between them may curve around a lake, mountain, restricted area, or neighborhood. The driving route could therefore be 12, 15, or more miles even though the geographic separation remains 10 miles.

This is why a result described simply as "distance" should always be interpreted according to the method used.

For a deeper comparison, see Driving Distance vs Straight-Line Distance.

How Is Straight-Line Distance Between Two Locations Calculated?

Straight-line geographic distance is usually calculated from the latitude and longitude of the two locations.

For a spherical Earth model, a common method is the Haversine formula.

The calculation uses:

  • latitude of Location 1;
  • longitude of Location 1;
  • latitude of Location 2;
  • longitude of Location 2;
  • an assumed Earth radius.

The output represents the shortest great-circle path between the two geographic points on that spherical model.

For the full mathematical method, see our Haversine Formula guide.

How Are City Locations Represented?

A city does not exist at one single mathematical point. It covers an area.

Distance tools therefore need a representative coordinate for each city. Depending on the data source, that coordinate may correspond to a city center, mapped place record, administrative center, or another reference point.

That means two calculators can produce slightly different city-to-city distances if they use different coordinates for the same city.

This is one reason it is useful to distinguish:

distance between city reference points

from:

distance between two exact GPS coordinates

If exact points matter, enter their latitude and longitude directly in the Distance Calculator.

How Do You Calculate Distance Between Two Cities?

To calculate direct distance between two cities, first identify geographic coordinates for each city and then calculate the great-circle distance between those coordinates.

For example, using these approximate coordinates:

City Latitude Longitude
New York City 40.7128 -74.0060
Los Angeles 34.0522 -118.2437

the spherical Haversine implementation used by our calculator gives approximately:

2,445.56 miles

or:

3,935.75 kilometers

That is direct geographic distance, not driving mileage.

If you want the number of miles you would actually travel by road, use the Driving Distance Calculator.

Example: New York City to Boston

Consider these approximate coordinates:

New York City: 40.7128, -74.0060
Boston: 42.3601, -71.0589

Using the same spherical great-circle method as our coordinate calculator gives approximately:

190.21 miles

or:

306.11 kilometers

This number describes direct geographic separation between the selected coordinates.

A driving route will be different because it must follow the road network.

Example: Los Angeles to San Francisco

Using approximate city coordinates:

Los Angeles: 34.0522, -118.2437
San Francisco: 37.7749, -122.4194

the great-circle distance is approximately:

347.42 miles

or:

559.12 kilometers

Again, this is not road mileage. It represents the direct geographic distance between the two coordinate points.

Why Can Two Distance Calculators Give Different Results?

Two calculators can return different distances because they may not be measuring the same thing.

Common causes include:

Different Distance Types

One calculator may report straight-line distance while another reports driving distance.

Different Location Coordinates

Two systems may assign slightly different latitude and longitude values to a city, ZIP code, airport, or landmark.

Different Earth Models

A calculator may use a spherical approximation while a higher-precision system uses an ellipsoidal Earth model.

Different Road Routes

Driving calculators may select different routes based on the routing engine or available road-network data.

Different Rounding

One tool may display whole miles while another displays one or two decimal places.

Before comparing two results, check what each calculator actually measures.

Is Distance Between Two Locations the Same as "As the Crow Flies"?

Only when the result is specifically a direct or straight-line geographic measurement.

"As the crow flies" generally refers to the direct geographic separation between locations without following roads.

A driving-distance result is therefore not an as-the-crow-flies distance.

Read our As the Crow Flies Distance guide for a fuller explanation of this measurement.

Can You Find Distance Between Two Locations Using GPS Coordinates?

Yes. GPS coordinates provide latitude and longitude values that can be used to calculate geographic distance.

For example:

Location A: 40.7128, -74.0060
Location B: 34.0522, -118.2437

A coordinate-based calculator can use those values directly.

Our Distance Calculator is designed for this exact task.

If you have coordinates rather than city names, using the coordinates directly also removes ambiguity about which point within each location is being measured.

Can You Calculate Distance Between Two Addresses?

Yes, but addresses need to be converted into geographic coordinates before geographic or route distance can be calculated.

That conversion process is called geocoding.

Our Distance Between Addresses Calculator is designed for address-to-address calculations and can provide both direct geographic distance and road-based distance.

For more detail on the conversion process, see How to Find Latitude and Longitude From an Address.

Can You Find Distance Between Two ZIP Codes?

Yes, but a ZIP code represents an area rather than one exact point.

A ZIP-code distance calculation therefore usually depends on representative coordinates associated with each ZIP code.

The result may not equal the distance between two specific homes, businesses, or addresses inside those ZIP-code areas.

See our guide to Distance Between ZIP Codes for the limitations and appropriate use of ZIP-based calculations.

Can You Measure Distance Between Two Locations on a Map?

Yes. Selecting two points on a digital map gives each point a geographic coordinate.

Those coordinates can then be used to calculate their direct geographic separation.

Use the Map Distance Calculator when you want to choose the locations visually instead of entering latitude and longitude manually.

This can be useful when the places you want to compare do not have convenient street addresses or recognizable place names.

What Is the Difference Between a Location and a Coordinate?

A location is a real-world place or position. A coordinate is a numerical way to identify a position.

For example:

Location: New York City

A representative coordinate might be:

40.7128, -74.0060

The location name is meaningful to people. The coordinate gives a mathematical position that a distance calculation can use.

A large place such as a city may have many possible coordinates depending on which point is being represented.

Does Distance Between Cities Measure City Center to City Center?

It depends on the data source.

A city-to-city calculator must assign a representative coordinate to each city. That may correspond approximately to the mapped city center or another location record.

The result should therefore be understood as the distance between the coordinates used to represent those cities, rather than the distance between every possible point inside them.

For exact distance calculations, use the coordinates of the specific locations you care about.

Which Distance Method Should You Use?

Choose the method according to the question you are trying to answer.

Your question Best method or tool
How far apart are these GPS coordinates? Distance Calculator
What is the direct distance between two places? Great-circle distance
How many miles will I drive? Driving Distance Calculator
How far apart are two addresses? Distance Between Addresses Calculator
How far apart are two selected map points? Map Distance Calculator
What is the distance between two ZIP-code areas? Distance Between ZIP Codes
How far will I walk along a route? Walking Route Distance Calculator

The best distance calculation is the one that matches the path or geographic relationship you actually want to measure.

How Does This Page Relate to the Distance Calculator?

This guide explains what "distance between two locations" can mean and helps you choose the correct measurement.

The Distance Calculator performs one specific calculation: great-circle distance between two latitude and longitude coordinate pairs.

That distinction keeps the calculator focused while this page explains the broader concept of location-to-location distance.

Frequently Asked Questions

What is the distance between two locations?

The distance between two locations is a measurement of how far one place is from another. The result can represent straight-line geographic distance, driving distance, walking distance, or another route-based measurement depending on the method used.

How do I calculate distance between two cities?

For direct geographic distance, use representative latitude and longitude coordinates for both cities and calculate their great-circle distance. For road mileage, use a routing-based Driving Distance Calculator.

Is distance between cities measured from the city centers?

Often a city-distance calculation uses representative coordinates associated with each city, but the exact reference point depends on the location data source. Different reference coordinates can produce slightly different results.

Why is driving distance longer than straight-line distance?

Driving distance follows the road network, while straight-line geographic distance measures the direct separation between two points. Roads may curve or detour around terrain, waterways, borders, and inaccessible areas.

Can GPS coordinates be used to calculate distance between places?

Yes. Latitude and longitude coordinates can be used directly to calculate geographic distance. Use the Distance Calculator when you know the coordinates of both points.

Can I calculate the distance between two places without knowing the coordinates?

Yes. A location-based, address-based, or map-based tool can first identify the coordinates for you. The best tool depends on whether you have city names, addresses, ZIP codes, or map locations.

Are city distance and flight distance the same?

Not necessarily. A straight-line city distance can approximate geographic air separation, but an actual flight route may differ because aircraft follow operational routes rather than necessarily traveling along the exact shortest surface path.

Need a calculation now?

Choose the calculator designed for your distance problem.

Explore Calculators