Home › Text & Utility › Compass Bearing Calculator
Text & Utility

Compass Bearing Calculator

A map makes two cities look like a straight line, but the shortest path between them curves across the globe — so the direction you set off in is not the direction you arrive facing, and on a long route the two can differ by more than a right angle. The bearing between two GPS coordinates is one line of spherical trigonometry, but nobody works atan2 by hand at the trailhead. This page runs it from any two latitude and longitude pairs, gives the initial bearing, the final bearing, the 16-point compass reading and the great-circle distance, and says plainly that the answer is true north, not magnetic north.

Free · No sign-up · Runs in your browser · First published 2026-11-04 · Updated November 2026

Enter decimal degrees, with north and east positive and south and west negative: New York is 40.7128, −74.0060 and London is 51.5074, −0.1278. The bearing is measured clockwise from true north, not from your compass needle — magnetic declination, which varies by place, must be applied separately before following it with a compass.

Initial bearing — set off facing
—
From New York, set off towardsInitial bearingGreat-circle distance
London (worked example)51.2° NE5,570 km / 3,461 mi
Paris53.7° NE5,837 km / 3,627 mi
Reykjavik34.1° NE4,203 km / 2,611 mi
Tokyo333.0° NNW10,852 km / 6,743 mi
Sydney266.0° W15,989 km / 9,935 mi

The bearing formula

A bearing is the clockwise angle from true north to the direction of travel, from 0° (north) through 90° (east), 180° (south) and 270° (west) back to 360°. On a flat map the bearing from A to B never changes, but on a sphere the shortest path — the great circle — curves against the meridians it crosses, so the bearing changes along the way. That is why the calculator reports two bearings: the initial bearing, the direction you face when you set off, and the final bearing, the direction you are facing when you arrive. The initial bearing comes from spherical trigonometry, with φ for latitude and λ for longitude, all in radians:

θ = atan2(sin Δλ × cos φ₂, cos φ₁ × sin φ₂ − sin φ₁ × cos φ₂ × cos Δλ)
Bar chart of the initial bearing from New York: Reykjavik is 34.1°, the worked example London is 51.2°, Paris is 53.7°, Sydney is 266.0° and Tokyo is 333.0°
Initial bearings from New York, drawn as bars: the worked example below sits at London = 51.2°.

Here φ₁ and λ₁ are the start point, φ₂ and λ₂ the destination, and Δλ = λ₂ − λ₁. The atan2 form matters: an ordinary arctangent cannot tell 51° from 231°, while atan2 reads the signs of both parts and lands in the right quadrant. The result is normalised into 0–360° by adding 360 and taking the remainder. The final bearing is found the same way in reverse — the bearing from the destination back to the start, plus 180°. The distance beside them is the haversine great-circle distance: a = sin²(Δφ ÷ 2) + cos φ₁ × cos φ₂ × sin²(Δλ ÷ 2), then d = 2 × 6,371 km × asin(√a).

Worked example: New York to London

New York is 40.7128°N, 74.0060°W and London is 51.5074°N, 0.1278°W, so Δλ = −0.1278 − (−74.0060) = 73.8782°. Feeding the four values into the formula: sin Δλ × cos φ₂ = 0.5979 and cos φ₁ × sin φ₂ − sin φ₁ × cos φ₂ × cos Δλ = 0.4805, so θ = atan2(0.5979, 0.4805) = 51.21°, shown as 51.2° NE — the published figure for this route is about 51°, northeast, exactly as expected. The final bearing is 108.3° (ESE): you set off northeast and arrive facing east-southeast, a swing of 57.1° across the Atlantic, which is why a navigator who held 51° all the way would miss London entirely. The haversine distance is a = 0.179236, c = 0.8743 radians, so d = 2 × 6,371 × 0.8743 = 5,570.2 km (3,461.2 mi, 3,008 nautical miles). The return leg starts at 288.3° (WNW). The table on the calculator shows the same arithmetic from New York to four more cities: Paris 53.7° over 5,837 km, Reykjavik 34.1° over 4,203 km, Tokyo 333.0° (NNW, over the pole side) over 10,852 km, and Sydney 266.0° (due west, across the Pacific side) over 15,989 km. Two sanity checks confirm the implementation: due east along the equator returns exactly 90°, and due north up a meridian returns exactly 0°.

How to read your result, and its limits

Four cautions decide what the bearing can be used for. First, it is a true bearing, not a magnetic one: compasses point to magnetic north, and the gap — magnetic declination — runs from a few degrees to more than 20° in places, changing slowly year by year, so a compass user must apply the local declination before walking the number. Second, it is the great-circle direction, not a constant compass course: holding the initial bearing all the way follows a rhumb line, a longer path that spirals towards the pole, so long routes need the bearing recomputed at waypoints or a great-circle route followed instead. Third, the Earth is treated as a sphere: the 6,371 km mean radius keeps the distance within about 0.5% of the WGS-84 ellipsoidal figure, which is plenty for hiking, sailing and flight planning but not for surveying. Fourth, antipodal points have no bearing: from a point to the point exactly opposite it on the globe, every direction is equally short, so the calculator refuses those inputs instead of printing an arbitrary angle.

Common mistakes

  • Following the initial bearing all the way. On a short walk the drift is negligible, but across an ocean the bearing swings by tens of degrees. Recompute at waypoints, or follow a plotted great-circle route.
  • Using the bearing straight on a compass. The calculator's north is true north at the geographic pole. A compass needle points to magnetic north: skip the declination correction and the whole route shifts by the local gap.
  • Mixing up final bearing and return bearing. The final bearing (108.3° for New York to London) is the direction you face arriving in London. The return bearing (288.3°) is the direction you set off from London to come home — a different number, and the calculator prints both so they are never swapped.
  • Entering west and south as positive. West longitudes and south latitudes are negative in decimal degrees. Entering 74.0060 instead of −74.0060 for New York silently moves the start point to central Asia, and every figure that follows is wrong.

Related tools: Hiking Time Calculator — Your trail time from distance and ascent by Naismith's Rule — walking time, breaks and arrival time, in metric or imperial units; Time Zone Converter — Convert a date and time between 20+ cities with real offsets — and see when the answer lands on another day; Altitude Acclimatization Calculator — A safe ascent, day by day — sleeping altitudes, daily gains and rest days from the 500-metre rule.

Frequently asked questions

What is the difference between initial bearing and final bearing?

The initial bearing is the compass direction you face when you set off along the shortest (great-circle) path; the final bearing is the direction you are facing when you arrive. On a sphere the path curves against the meridians, so the two differ — New York to London sets off at 51.2° NE and arrives facing 108.3° ESE.

Is this a true bearing or a magnetic bearing?

True: it is measured clockwise from the geographic North Pole. A magnetic compass points to magnetic north instead, which differs by the local magnetic declination — from a few degrees to more than 20° depending on location — so apply your local declination before following the bearing with a compass.

Why is the bearing from New York to Tokyo 333°, not east?

Because the shortest path from New York to Tokyo runs north over the Arctic side of the globe, not east across the map: a flat map stretches the high latitudes and hides the curve. The great-circle route sets off NNW at 333.0° and covers 10,852 km, shorter than any eastward-looking rhumb line.

How accurate is the distance?

It uses the haversine formula on a spherical Earth of 6,371 km radius, which agrees with the WGS-84 ellipsoidal distance to within about 0.5% — a few kilometres on a transatlantic route. That is plenty for hiking, sailing and flight planning; surveying work needs a geodesic (Vincenty) calculator instead.

Ahsan ul Haq
Editor, ToolFigure

Every ToolFigure calculator is checked against hand-worked examples before it is published — the same worked examples you can follow on each page. More about ToolFigure →

Related tools

Calculators that show their working

Free forever · No sign-up · Every result comes with its formula and a worked example.

Browse all tools