simplemaplab

Multi-Stop Route Distance Calculator

Total trip mileage across up to 25 waypoints — crow-flies and driving distance side by side, per-segment breakdown, optional round-trip and best-order optimization. Free, worldwide, no sign-up. Built on the haversine formula and the open-source Valhalla routing engine on OpenStreetMap.

Or click the map to add a stop. Up to 25 waypoints.
Try:
Loading map…

Add at least two waypoints to compute the multi-stop trip distance. Search any city, click the map, or paste a list of addresses.

Why a multi-stop tool, and how it differs from 2-point distance tools

Most distance calculators on the web answer a single question: "how far is point A from point B?" That is enough for a flight comparison or a "is this house close to the school" check. It is not enough for a real estate agent showing six properties in an afternoon, a sales rep with twelve customers in a day, a wedding planner touring eight venues, or a road-tripper with seven stops between Los Angeles and the Grand Canyon. Those situations need cumulative distance across an ordered list of stops, plus per-leg breakdowns so you can plan time in the day around each segment.

That is what this tool computes. You add up to 25 waypoints — by search, GPS, map click, or bulk paste — and the tool sums the haversine crow-flies distance across consecutive pairs, while in parallel calling the Valhalla routing engine once per segment to get the actual road distance and drive time. The three result cards show the totals: total crow-flies in mi / km / nm, total driving in mi + total drive time, and the detour percentage (how much longer the road version is). The per-segment table breaks every leg down with from / to, crow-flies miles, driving miles, drive time, and bearing.

On top of that we add two features that single-pair calculators cannot offer. Round-trip toggle appends a return leg from the last stop to the first, so the total reflects the full out-and-back day. Best order runs a nearest-neighbor + 2-opt TSP heuristic that re-sequences the middle waypoints to minimize total crow-flies distance — the same algorithm a paid logistics tool uses, just exposed free, in a single click. For 25 or fewer stops it lands within a few percent of optimum in milliseconds.

How to compute total distance across a multi-stop trip

Six steps from blank canvas to a fully-summed, exportable route.

  1. Add your first waypoint. Type a city, address, or landmark in the search box and pick a result, tap "Use My Location" to seed the trip with your current GPS, or click anywhere on the world map. The first waypoint becomes the start of the route — pin number 1.
  2. Add the rest of your stops. Repeat the search, GPS, or map-click flow for every additional stop, up to 25 waypoints. Each new waypoint is appended to the end of the list and gets its own numbered pin on the map. You can also click "Paste list" to bulk-import a list of addresses or "lat, lng" lines from a spreadsheet.
  3. Reorder, drop stops, or pick "Best order". Use the ↑ / ↓ buttons in the stops list to manually reorder, the × button to remove a waypoint, or click "Best order" to run a nearest-neighbor + 2-opt optimization that minimizes total crow-flies distance while keeping waypoint #1 fixed as the start. The map and totals refresh instantly.
  4. Toggle round-trip and driving distance. Tick "Round trip" to add a return leg from the last stop back to the first. Tick "Driving distance" to fetch real road distance and drive time for every segment in parallel from the open-source Valhalla routing engine. Both toggles update the totals and the per-segment table live.
  5. Read the totals and the segment table. The three result cards show the total crow-flies distance (in mi, km, nm), the total driving distance and drive time (with progress while segments load), and the detour percentage — how much further you actually drive compared to the bee-line. The per-segment table breaks the trip down with from / to, crow-flies miles, driving miles, drive time, and bearing.
  6. Export, share, or save. Hit "Download CSV" to export the full waypoint list and per-segment breakdown — useful for client mileage reports, expense filings, route briefings, or pasting into a spreadsheet. The full state of the tool (waypoints + round-trip flag) is encoded into the URL hash, so copying the URL from the address bar is enough to share or re-open the trip later.

What people use this tool for

Seven common patterns we see in the search analytics and customer support tickets.

Real estate showing tours

A buyer-agent showing six candidate properties in a single afternoon needs the total miles plus a per-property leg breakdown for the trip log and IRS Form 2106. The multi-stop tool takes addresses pasted from the MLS, resolves them, computes each leg in road miles, and totals the trip — including a "best order" option that re-sequences the showings to minimize wasted driving. Detour percentage shows how much road overhead a poor sequence is adding.

Sales territory route planning

A field sales rep with a 12-account day needs to know whether the visit list fits inside an 8-hour driving window before leaving the office. Paste the customer list, hit "Best order", and the tool returns a nearest-neighbor + 2-opt sequence with per-leg drive times. Total drive time of 4 hours leaves 4 hours of customer face-time across 12 stops — a realistic day. 7 hours of drive time means cutting accounts.

Road trip planning

Cross-country road trips have a flexible order. Add the must-see stops in any sequence and click "Best order" — the tool computes a sensible loop. Round-trip mode adds the leg home for total mileage. The per-segment table doubles as a fuel and drive-day estimator: split a 1,800-mile trip into legs of 250–350 miles to match a 5–6 driving-hour day.

Delivery and last-mile logistics

Small couriers, florists, and locksmith vans plan routes manually instead of paying for a TMS. The multi-stop tool gives a free per-segment driving distance and time across up to 25 stops, with a best-order optimizer for the route and CSV export for the day-of-driver paperwork. For one-vehicle, one-day routes this matches the output of paid tools (RouteXL, Roadwarrior) at the small-N end.

Event venue and site visit tours

Wedding planners, architects, and film location scouts visit 5–8 candidate venues in a day. The tool plans the visit order and gives an honest drive-time budget so the day actually finishes on time. Detour percentage flags poor sequencing — if driving distance is +60% over the crow-flies, swapping two stops can usually save 10–20 miles.

Photography location scouting

Landscape photographers chase light at multiple viewpoints in a single day. The tool plans the sequence with bearing per leg (useful for sun-angle planning), per-leg drive time, and a detour figure that helps decide whether to combine two shots or spread them across days. Pair the export with a sunrise / sunset calculator for golden-hour timing at each stop.

Multi-city business travel

Three-city consulting trips ("LA Tuesday, Phoenix Wednesday, Denver Thursday") still benefit from a multi-stop distance view, even when the segments are flights. The crow-flies figure approximates the great-circle flight distance airlines use for fare calculation; the per-segment bearings double as a quick "Boeing in-flight map" reference. Driving distance is unreachable for inter-city flights — the tool flags those segments cleanly without bombing.

Famous multi-stop routes — distances at a glance

Eight popular multi-stop trips with pre-computed crow-flies and approximate road distances. Detour percentage flags how road-efficient each route is — Texas Triangle and California Coast are below 20% (mostly straight freeways), New England Fall and Pacific Northwest Loop are above 25% (winding mountain roads).

RouteStopsCrow-fliesBy roadNotes
5-City NYC TourTimes Sq → Central Park → Empire State → Brooklyn Bridge → Statue of Liberty7.8 mi11 miManhattan grid + harbor ferry. Driving overhead ~40%.
California CoastSF → Half Moon Bay → Santa Cruz → Monterey → Big Sur → Cambria218 mi244 miHighway 1 follows the coast; detour low at +12%.
New England FallBoston → Concord → Stowe → North Conway → Bar Harbor329 mi413 miMountainous secondary roads inflate driving by 25%.
Florida KeysMiami → Key Largo → Marathon → Big Pine Key → Key West127 mi161 miOverseas Highway threads through the keys; detour ~27%.
Pacific Northwest LoopSeattle → Mt Rainier → Mt St Helens → Portland → Astoria → Olympia → Seattle442 mi604 miRound trip, mountainous; highest detour percentage.
Southwest National ParksLas Vegas → Zion → Bryce → Capitol Reef → Arches → Grand Canyon → Vegas1,054 mi1,382 mi6-stop loop, mostly highway, +31% detour.
European Capitals (5)London → Paris → Brussels → Amsterdam → Berlin973 mi1,156 miEurotunnel + autobahn-grade roads, +19%.
Texas TriangleHouston → Austin → San Antonio → Dallas → Houston743 mi839 miI-10 / I-35 / I-45 — among the most road-efficient in the US.

The mathematics behind the result

Every figure in the result panel is derived from a small set of well-known formulas. They are below in case you want to verify, audit, or reimplement them.

QuantityFormulaNotes
Per-segment crow-flies distance — haversined_i = 2R · asin(√(sin²(Δφ/2) + cos φ₁ · cos φ₂ · sin²(Δλ/2)))φ = latitude (rad), λ = longitude (rad), R = 6,371 km (IUGG mean Earth radius).
Total trip distanceD_total = Σᵢ₌₁ⁿ⁻¹ d(wp_i, wp_{i+1}) + d(wp_n, wp_1) (if round-trip)Sum of all segment distances. For n waypoints there are n−1 legs (or n with round-trip).
Initial bearing per segmentθᵢ = atan2(sin Δλ · cos φ₂, cos φ₁ · sin φ₂ − sin φ₁ · cos φ₂ · cos Δλ)Forward azimuth at the start of each leg. Useful for in-flight or in-vehicle heading.
Best-order — TSP nearest-neighbor + 2-optNN: pick nearest unvisited next; 2-opt: while ∃ (i,k): swap edges (i−1,i)+(k,k+1) → (i−1,k)+(i,k+1) reduces tourHeuristic. NN runs in O(n²); 2-opt typically converges in a handful of passes for n ≤ 25. Not globally optimal for hard TSP instances; in practice within a few percent of optimum.
Detour percentage((D_road − D_crow_flies) ÷ D_crow_flies) × 100%Always ≥ 0 in practice. Ranges from 5–10% on straight freeways to 60–100%+ across water or mountains.
Per-segment driving (Valhalla)D_road_i = trip_summary.length; T_road_i = trip_summary.timeLowest-cost path through the OSM road graph using contraction hierarchies, "auto" cost model. 1,500 km path-length cap on the free FOSSGIS instance.

How the tool actually works

1. Crow-flies math, summed across the trip

We treat Earth as a sphere of radius 6,371 km (the IUGG mean radius) and use the haversine formula for each consecutive pair of waypoints. The math runs entirely in the browser; no server round-trip is needed. Total trip distance is just the sum of all per-segment haversine distances. If round-trip is on, we add one more segment from the last waypoint back to the first. Haversine is numerically stable for very small distances (down to centimetres) and avoids floating-point rounding errors near the antipodes.

2. Driving distance via Valhalla — one call per segment

We proxy the FOSSGIS-hosted public Valhalla service at valhalla1.openstreetmap.dethrough our own /api/routeendpoint, which adds caching and graceful error handling. For N waypoints we make N−1 parallel requests (or N requests with round-trip on), throttled to 4 concurrent so we do not hammer the upstream. Per-segment results are cached for 24 hours upstream so common routes get fast subsequent loads. The free Valhalla instance has a 1,500 km path-length cap; segments that exceed it (e.g., a leg from Miami to Vancouver) come back as "n/a" rather than failing — we surface that gracefully in the per-segment table and the totals card.

3. Optimize-order algorithm — nearest-neighbor + 2-opt

The travelling salesman problem (TSP) is NP-hard — finding the provably optimal tour for 25 cities means evaluating up to 24! ≈ 6.2 × 10²³ permutations, which is not practical for a click-and-wait UI. We instead use the standard textbook heuristic: nearest-neighbor as a starting tour (greedy: at each step pick the nearest unvisited waypoint), followed by 2-opt local search (repeatedly swap pairs of edges if the swap shortens the tour). Six 2-opt sweeps almost always converge to a local optimum within 2–5% of the global optimum for n ≤ 25, and runs in milliseconds. The first waypoint stays fixed as the start because that is usually a depot, home, or office; all other waypoints can be reordered.

4. Map drawing — antimeridian-aware great-circle polylines

For each pair of consecutive waypoints we compute the great-circle path with spherical linear interpolation (SLERP) on the unit sphere — 64 sample points per segment. These get rendered as one or more LineString features on the MapLibre vector-tile basemap. When a path crosses the 180° meridian (Tokyo → Honolulu, Anchorage → Magadan), we split the polyline at the jump so the line draws cleanly without wrapping all the way around the world. The polyline is dashed red (#c44536) at 3-pixel width, distinct from the numbered green pin markers (#2a6e4e).

5. Place names

Place-name autocomplete uses Photon (typo-tolerant geocoder by Komoot, hosted at photon.komoot.io). Reverse geocoding for map clicks (turning latitude / longitude into a place name) uses Nominatim. Both are free and run on OpenStreetMap data — the same OSM that Valhalla uses for the road network — so place names and routes are in lockstep. The CSV-import flow geocodes one address at a time with a 600 ms politeness delay between requests.

How this tool compares to other multi-stop route tools

Quick comparison against the major free and paid multi-stop route distance tools on the web.

FeatureSimpleMapLabGoogle MapsRoadwarrior / RouteXLMapQuest Route Planner
Free, no sign-upLimited / paidLimited / paid
Up to 25 waypointsLimited (10)
Best-order optimization (TSP)✓ (paid)
Round-trip toggle
Per-segment drive distance + timeLimited
Crow-flies + driving side-by-side
Detour percentage (driving vs straight)
CSV exportPaidPaid
Bulk-paste address list
Click-to-add waypointsLimited
Worldwide coverageUS/EU onlyVariable
Antimeridian-aware path drawing
No watermark, no rate limitSome adsAPI limitAPI limit
Mobile-first interfacePartialPartial

Related tools and resources

For a single-segment distance, our distance-between-two-places gives a clean haversine number with multiple unit toggles, and crow flies distance adds the side-by-side driving distance and detour percentage for that one pair. To see how far you can travel from a single point in a given time budget — drive, bike, or walk — drive time map renders a true isochrone (drivable area) rather than a circle.

For finding the geographic midpoint between two stops — useful for "let\u2019s meet halfway" planning between two of the waypoints — see halfway between two places. For getting the bearing math (initial, final, rhumb-line, magnetic) along any one segment, bearing & compass calculator is the right tool. To convert an address to coordinates first (for clean CSV input), use address to coordinates.

For visual annotation rather than distance math: pin drop map lets you drop up to 100 pins with notes and colors and share via URL, and CSV to map plots a CSV of lat / lng on an interactive map with category coloring. Both are complementary to multi-stop distance — they are about showing a list of places, not summing the distances between them.

Frequently asked questions

A 2-point distance tool tells you how far apart two places are. A multi-stop tool sums the distance across an ordered list of waypoints — useful when you have to visit five customers, six campsites, or eight wedding venues in a single trip. We do this for both the straight-line crow-flies distance and the actual road driving distance, side by side, and we add up the totals automatically. We also let you toggle a round-trip return leg and run a best-order optimizer that re-sequences the stops to minimize total mileage.
For crow-flies we use the haversine formula on a spherical Earth (R = 6,371 km, the IUGG mean radius), computed entirely in your browser — no server round-trip. We compute one segment per consecutive waypoint pair and sum them. For driving distance, each segment is a separate request to the open-source Valhalla routing engine (proxied via /api/route on this site) — N waypoints means up to N−1 parallel calls, throttled to 4 concurrent requests to stay polite to the upstream service. The detour percentage is just (road_total − crow_flies_total) ÷ crow_flies_total × 100%.
Up to 25. That covers a typical real estate showing day, a sales rep day, a road trip, or a small delivery route. Above 25 the math is the same but the UI gets unwieldy and the upstream Valhalla calls add up — for routes with more than 25 stops you generally want a dedicated TMS (transportation management system) anyway, since the ordering problem becomes genuinely hard at that size.
Very. Haversine on a spherical Earth is accurate to within ~0.5% for any practical purpose, and the rounding error in 5-decimal latitude / longitude is 1 m or less. For sub-metre work you would switch to the WGS-84 ellipsoid with Vincenty’s formulas, but for trip planning, real estate, expense reports, and logistics, the spherical model is more than sufficient.
The driving distance is the path length along the road graph that Valhalla finds for the lowest-cost route, which matches very closely to what a turn-by-turn navigation app would say. The drive time is a free-flow estimate based on posted speed limits and road category — not real-time traffic. Compared to off-peak Google Maps, our drive time is typically within 5–10%; during rush-hour traffic on a congested freeway, our number will under-estimate by a wider margin since it does not see the jam.
It runs a two-stage heuristic. First a nearest-neighbor sweep — start from waypoint #1 (kept fixed as the start), repeatedly walk to the nearest unvisited waypoint, repeat. NN gives a decent but rarely optimal tour. Second, a 2-opt pass that repeatedly looks for pairs of edges whose swap shortens the tour and applies them, up to 6 sweeps. For 25 or fewer waypoints, this typically lands within a few percent of the global optimum, in milliseconds. The first waypoint stays as the start (because that is usually a depot, home, or office); all other waypoints can be reordered.
No. The travelling salesman problem is NP-hard — finding the provably optimal tour for 25 cities means evaluating up to (24!) permutations, which is roughly 10²³. Nobody waits that long. The NN + 2-opt heuristic we use is the same one taught in undergrad operations-research courses; it gets within ~2–5% of optimum on most realistic instances and runs in milliseconds. For a road trip or sales day this is far better than human ordering and indistinguishable in practice from optimal.
Yes, for one-vehicle, one-day routes up to ~25 stops. For multi-vehicle fleet routing, time-window constraints, capacity constraints, or 100+ stops, you need a dedicated routing solver (RouteXL, OptimoRoute, Routific, OR-Tools). We solve the simple TSP with a fixed start; we do not solve the vehicle routing problem (VRP) or its variants. For locksmith vans, florist deliveries, repairman day routes, courier microbatches, and similar small-N use cases, this tool covers it.
The free FOSSGIS Valhalla instance caps any single route at 1,500 km of path length. Continental North America east-to-west, transatlantic flights, or any segment from Miami to Vancouver exceeds the cap. In those cases we cleanly mark the segment as "n/a" in the per-segment table and warn that N segments are unreachable in the totals card. The crow-flies number still computes correctly — the haversine formula has no cap.
Yes. The full state of the tool (every waypoint with its lat / lng / label, plus the round-trip flag) is encoded as compact JSON, base64-ed, and stored in the URL hash (the part after the # in the address bar). Copy the URL from the address bar and send it — anyone with that link will load the same trip. No sign-up, no server-side database, no expiration. The only caveat is that very long trips (25 waypoints with long labels) produce long URLs; consider the CSV export for archival.
Yes, optimized. Touch targets are ≥44 px, inputs use 16 px font (which prevents iOS’s zoom-on-focus), the result cards stack 1-up below 720 px, the map collapses to 320 px, and the per-segment table hides the bearing column on narrow screens. Best on mobile in landscape, but works fine in portrait too.
One waypoint per line. We accept either of two formats per line: (1) a literal latitude / longitude pair like "40.7128, -74.006" — the regex requires "<num>, <num>" with valid lat / lng ranges; (2) any free-form address, city, landmark, or place name like "Eiffel Tower" or "1600 Pennsylvania Ave NW, Washington DC" — these are geocoded one-by-one through Photon (typo-tolerant geocoder). Geocoding waits 600 ms between requests to be polite to Photon’s free service. Lines that fail to parse or geocode are silently skipped; the rest are appended to the trip.
Coordinates are direct (no geocoding, no risk of ambiguity), but most users do not have lat / lng handy. Addresses go through Photon — works for almost any place name worldwide, but ambiguous queries ("Springfield" or "Main Street") can geocode to the wrong place. Best practice for an unfamiliar city: paste full addresses with city + state / country. For coordinates from another GIS tool: paste them as "lat, lng" — it is the most reliable input.
For routes that cross the 180° meridian (e.g., Tokyo → Honolulu, Anchorage → Magadan), the great-circle path arcs across the line. Naïvely drawing a polyline from longitude 178 to longitude −175 would render as a line all the way around the world. We compute the great-circle path with spherical-linear-interpolation (SLERP) at 64 sample points per segment, then split the polyline at any pair of consecutive samples that jump more than 180° of longitude. Each segment renders as one or more LineString features; the visible path is correct on every projection.
Distance Between Two Places gives a clean great-circle distance for two points; Crow Flies Distance compares straight-line vs driving for two points; this tool extends both to N points (up to 25) with totals and TSP optimization. If you need just one segment, Distance Between Two Places is the cleanest UX. If you have two points and want the driving comparison, Crow Flies Distance. If you have three or more, this is the right tool.

Data sources & methodology

Crow-flies distance:haversine formula on a spherical Earth, R = 6,371 km (IUGG mean radius), summed across consecutive waypoints. Public-domain math, computed in the browser.

Driving distance and time: per-segment lookup against Valhalla routing engine (open-source, Linux Foundation) on OpenStreetMap data. Hosted by FOSSGIS at valhalla1.openstreetmap.de. 1,500 km path-length cap on the free instance.

Best-order optimization:nearest-neighbor heuristic followed by 2-opt local search, up to 6 sweeps. First waypoint kept fixed as the start. Public-domain algorithm; lands within ~2–5% of optimum on most instances of n ≤ 25.

Place-name search: Photon (typo-tolerant geocoder, by Komoot) and Nominatim (OpenStreetMap reverse geocoder).

Maps: MapLibre GL JS with OpenFreeMap "Liberty" vector tiles. Last reviewed 5 May 2026.

More distance and routing tools

Crow Flies Distance

2-point straight-line vs driving distance with detour percentage.

Distance Between Two Places

Single-segment great-circle distance with multiple unit toggles.

Drive Time Map

Isochrone — how far you can drive, bike, or walk in N minutes.

Pin Drop Map

Up to 100 pins with notes and colors. Shareable URL, CSV / GeoJSON / KML export.