What is Latitude/Longitude?
Latitude, measured in degrees (°), is the angle between a point on Earth and the Equator. Earth's Equator is an imaginary line that divides the planet horizontally exactly halfway between the South and North Pole. A point's latitude must be between −90° (South Pole) and +90° (North Pole), with 0° at the Equator.
Longitude is the angle between a point and the prime meridian — an imaginary vertical line passing near the Royal Observatory in Greenwich, London. Longitude ranges from −180° (west of the prime meridian) to +180° (east).
Coordinates are expressed as (latitude, longitude). For example, the Empire State Building is at (40.7484°, −73.9857°) — meaning 40.7484° north of the Equator and 73.9857° west of Greenwich.
The Haversine Formula
The haversine formula calculates the great-circle distance between two points on a sphere given their latitudes and longitudes. It is the standard method used in navigation and geospatial applications. The formula assumes Earth is a perfect sphere with a mean radius of 6,371 km (3,958.8 mi).
The formula:
a = sin²(Δlat/2) + cos(lat₁) · cos(lat₂) · sin²(Δlon/2) c = 2 · atan2(√a, √(1−a)) d = R · c
Where:
- Δlat = difference in latitude (radians)
- Δlon = difference in longitude (radians)
- R = Earth's radius (6,371 km or 3,958.8 miles)
- d = great-circle distance
Getting the Distance Between Two Points on Earth
To find the distance between two coordinates, you need the latitude and longitude of each point in decimal degrees. Positive latitude = North, negative = South. Positive longitude = East, negative = West.
This calculator also shows:
- Distance in all common units: kilometers, meters, miles, feet, yards, nautical miles
- Initial bearing: the compass direction from Point 1 toward Point 2
- Midpoint coordinates: the geographic center between the two points
Examples Using the Latitude Longitude Distance Calculator
Example 1: New York City to London
- New York (Empire State Building): 40.7484°, −73.9857°
- London (Big Ben): 51.5007°, −0.1246°
- Distance: ≈ 5,570 km (3,461 miles)
- Bearing: ≈ 51° (NE)
Example 2: Los Angeles to Sydney
- Los Angeles: 34.0522°, −118.2437°
- Sydney: −33.8688°, 151.2093°
- Distance: ≈ 12,077 km (7,503 miles)
Example 3: Two points in the same city
- Eiffel Tower: 48.8584°, 2.2945°
- Louvre Museum: 48.8606°, 2.3376°
- Distance: ≈ 3.07 km (1.91 miles)
Metric vs. Imperial Units
- Metric: kilometers (km) and meters (m) — used in most countries worldwide
- Imperial (US): miles and feet — used primarily in the United States
- Nautical miles (nmi): used in aviation and maritime navigation; 1 nautical mile = 1,852 m = 1.15078 statute miles
FAQs
How accurate is the haversine formula?
The haversine formula treats Earth as a perfect sphere and is accurate to within about 0.3% for most distances. For very precise geodetic work, the Vincenty formula or WGS-84 ellipsoid model is used instead. For everyday navigation, haversine is more than sufficient.
What is great-circle distance?
A great-circle distance is the shortest path between two points on the surface of a sphere. It corresponds to the arc of a circle whose center is the center of the Earth. Flights typically follow great-circle routes to minimize fuel consumption.
What is a nautical mile?
A nautical mile is defined as exactly 1,852 meters (6,076 feet). It was originally defined as one minute of arc along a meridian. It is the standard unit for distances in air and sea navigation.
What is bearing (initial azimuth)?
The bearing is the compass direction from Point 1 to Point 2 measured clockwise from north (0°–360°). For example, 90° = East, 180° = South, 270° = West. The compass abbreviation (N, NE, E, etc.) is also shown.
Can I enter coordinates with N/S/E/W notation?
This calculator uses decimal degrees. To convert from degrees-minutes-seconds (DMS) or compass notation, simply apply the sign: S and W are negative. Example: 40°44'N → +40.7333°; 74°00'W → −74.0000°.