# Latitude Longitude Distance Calculator

URL: https://speedycalculator.com/calculators/other/haversine-distance/
Last updated: 2026-10-25

> The latitude and longitude distance calculator finds the great-circle distance between two points on Earth using the haversine formula, plus the initial compass bearing.

## Inputs

- Latitude 1 (°) — Example: Lahore
- Longitude 1 (°)
- Latitude 2 (°) — Example: Karachi
- Longitude 2 (°)

## Results

- Distance
- Initial bearing

## Formula

```
a = sin²(Δφ/2) + cos φ₁ cos φ₂ sin²(Δλ/2)
d = 2R × atan2(√a, √(1 − a))
```

## Explanation

The great-circle route is the shortest path over the Earth’s surface, which is why long-haul flights appear curved on flat maps.

### How to use the Latitude Longitude Distance Calculator

- **Latitude 1** — Example: Lahore
- **Longitude 1**
- **Latitude 2** — Example: Karachi
- **Longitude 2**

Results update as you type, and every field accepts the units shown in its menu.

### How it works

The haversine formula handles small and large distances accurately on a spherical Earth of radius 6,371 km.

### Inputs explained

FieldWhat to enterLatitude 1In °. Example: LahoreLongitude 1In °Latitude 2In °. Example: KarachiLongitude 2In °

### Example values

How the main result changes when **Latitude 1** changes and everything else stays at the example values above:

Latitude 1 (°)Distance (km)15.761,269.223.64758.131.521,03339.41,757.347.282,576.363.044,280.2

## Worked example

Inputs — Latitude 1: 31.5204 °; Longitude 1: 74.3587 °; Latitude 2: 24.8607 °; Longitude 2: 67.0011 °.

Results — **Distance = 1,033 km**; Initial bearing = 226 °.

## FAQ

**How accurate is this?**
Within about 0.5% because Earth is slightly flattened.

**Is road distance the same?**
No, roads are longer than the straight great-circle line.

**What formula does the Latitude Longitude Distance Calculator use?**
a = sin²(Δφ/2) + cos φ₁ cos φ₂ sin²(Δλ/2).

