Distance Matrix API Pricing Comparison: Google vs. Mapbox vs. HERE vs. Geocodio
What Google, Mapbox, HERE, and Geocodio charge per distance calculation plus matrix size limits, storage rules, and which distance API services let you keep the results.
Last updated: July 15, 2026. All information regarding other providers is accurate to the best of our knowledge using information from each provider's website as of that date.
What’s included in a distance API?
Before comparing prices, it helps to name what is being sold. "Distance" covers three different calculations, and most distance APIs only support one or two of them.
Straightline (haversine) distance. The geometric distance between two points, as the crow flies. Useful for radius filters, service-area screening, and building a shortlist of nearest locations. Google, Mapbox, and HERE do not offer it as a product.
Road-network driving distance and time. Distance and typical drive time over actual roads, without live conditions. This is the workhorse for analytics, site selection, territory planning, and logistics modeling. All four providers offer it.
Live-traffic driving time. ETAs that reflect current road conditions, for real-time dispatch and consumer-facing arrival estimates. Google prices it as a separate, more expensive tier. Mapbox and HERE include it with tighter matrix size limits. Geocodio does not offer live traffic and returns typical drive times using road networks instead.
One thing the major distance APIs agree on is the billing unit. A distance matrix request is billed per element, which is the number of origins multiplied by the number of destinations. A request with 10 origins and 50 destinations is 500 elements, whether it arrives as one API call or many.
Distance matrix pricing and features at a glance
In addition to the type of distance calculations offered by the distance API, there are several other considerations to think about when choosing a distance API:
Are you starting from addresses or coordinates? All distance APIs listed except Geocodio require you to pre-geocode your addresses first, and this should be considered when estimating costs.
Matrix size. How many origins and destinations do you have?
Do you need to keep the results? Most providers except for Geocodio prohibit long-term storage of results.
We’ve summarized these below for Google, Mapbox, HERE, and Geocodio.
| Provider | Straightline (haversine) | Driving (general distance/time) | Driving (live traffic) | Free tier | Largest matrix per request | Can you store results? | Key conditions | Countries supported |
|---|---|---|---|---|---|---|---|---|
| Geocodio | 1 credit/pair ($1/1,000 credits for self-serve, $2/1,000 for Enterprise) | 2 credits/pair ($/1,000 credits for self-serve, $2/1,000 for Enterprise) | 2,500 credits/day, shared across all Geocodio products | 10,000 elements, or 50,000 per async job, no geographic constraints | Yes, unrestricted | If starting from addresses, results an can be stored, analyzed, joined, and reused with no time limit. Batch and automated queries permitted. | US, Canada, Mexico, UK | |
| Google Routes API | Not offered | $5.00/1,000 (Essentials SKU) | $10.00/1,000 (Pro SKU) | 10,000 elements/mo (Essentials), 5,000/mo (Pro) | 625 elements, 100 with traffic-optimized routing | No | Content cannot be cached or stored beyond narrow carve-outs. All content must be deleted when the contract ends. | Global |
| Mapbox Matrix API | Not offered | $2.00/1,000 | $2.00/1,000 (driving-traffic profile, 10 coordinates) | 100,000 elements/mo | 625 elements (25×25), 100 for driving-traffic | No | Default terms prohibit exporting, caching, or storing results. Bulk and automated queries are also prohibited. No storable tier exists for Matrix results. | Global |
| HERE Matrix Routing | Not offered | About $5.00/1,000 list (volume tiers apply) | Included, for region-limited requests | 2,500 transactions/mo | 15×100, unless all locations fit within 400 km (about 250 miles), then up to 10,000×10,000 | No (30-day cache) | 30-day cache cap. Platform Terms prohibit using HERE materials with machine learning or AI systems. | Global |
List prices before free tiers and volume discounts, as of July 2026. Competitor rates are per 1,000 elements. Geocodio rates are shown in credits per pair, since geocoding, distance, and data appends all draw from the same credit pool. The "from coordinates" columns assume you already have coordinates. Google, Mapbox, and HERE accept nothing else as input. The "from addresses" column adds each provider's own geocoding rate, since most real-world data starts as addresses rather than coordinates.
Beyond the big three, TomTom bills per element with a discount rule for large matrices (when both dimensions exceed 5, you are charged for the larger dimension times 5), Azure Maps bills one transaction per 4 matrix cells, TravelTime sells flat-rate unlimited matrices, and open-source routers like OSRM and Valhalla are free if you run the servers and maintain the map data yourself. When comparing quotes, convert everything back to origins times destinations.
The HERE limit deserves a closer look before you build on it. HERE's 10,000×10,000 matrices are the largest of any provider on paper, but they require every origin and destination to fit inside a bounding region no more than 400 km (about 250 miles) across. That works for a single metro area or a small state. For anything larger, like warehouse-to-customer matrices across the US or Canada, HERE's cap drops to 15 origins by 100 destinations per request. Geocodio's 10,000-element requests and 50,000-element jobs have no geographic constraint: origins in Seattle, destinations in Miami, one request.
Geocodio prices distance in plain credits. Each origin-destination pair costs 1 credit for straightline distance or 2 credits for driving distance and time, at $1.00 per 1,000 credits pay-as-you-go ($2.00 per 1,000 credits on Enterprise plans). Addresses are geocoded for 1 credit each, and supplying coordinates or Stable Address Keys skips that charge entirely. Read the Distance docs.
Source documents: Google Routes API usage and billing, Mapbox Matrix API docs and Mapbox pricing, and the HERE Matrix Routing documentation. For storage and usage terms: Google Service Specific Terms, Mapbox Product Terms, and HERE Platform Terms. Google marked its older Distance Matrix API as Legacy, so new builds are directed to the Routes API's Compute Route Matrix, which is what is priced here.
Consideration: Is pre-geocoding required?
Google, Mapbox, and HERE matrix APIs require coordinates as input. If your data starts as addresses, which most CRM exports, patient lists, and delivery manifests do, you need to pay for a separate geocoding step with its own API calls, its own pricing, and its own storage terms before you can calculate a single distance. That step rarely appears on the same pricing page as the matrix rates.
Geocodio's Distance API accepts addresses directly and geocodes them as part of the request, at the normal rate of 1 credit per address. If you already have coordinates, or you have previously geocoded the data and kept the Stable Address Keys, you skip the geocoding charge entirely and pay only for the distance calculations. Geocodio Unlimited customers skip it too: the geocoding component of a distance request runs on their dedicated instance, so credits are only spent on the distance calculations themselves.
Worked example: 100 origins × 100 destinations
A 100 × 100 matrix is 10,000 elements. Here is the list-price cost of running it once, quoted two ways: starting from coordinates you already have, and starting from addresses with the same provider geocoding them first.
Two practical differences do not show up in the dollar figures. Because Google and Mapbox cap requests at 625 elements, this matrix takes at least 16 API calls with them. And HERE returns it in a single request only if all 200 locations fit inside a region 400 km (about 250 miles) across. Spread them wider and HERE's 15×100 cap applies, which means at least 7 requests. Geocodio returns it in one request regardless of geography.
| Provider | Driving, from coordinates | Driving, from addresses (geocoding included) | Straightline, from addresses | Can you keep the results? |
|---|---|---|---|---|
| Geocodio | $20.00 | $20.20 | $10.20 | Yes |
| Google Routes API | $50.00 | $51.00 | Not offered | No |
| Mapbox Matrix API | $20.00 | $21.00 | Not offered | No |
| HERE Matrix Routing | $50.00 | About $50.20 | Not offered | No (30-day cache) |
How these numbers were calculated
List prices before free tiers and volume discounts. The "from coordinates" column is the matrix calculation alone. The "from addresses" column adds 200 geocodes (100 origins plus 100 destinations) with the same provider. Geocodio: 10,000 pairs at 2 credits each (driving) or 1 credit each (straightline), plus 200 geocoding credits when starting from addresses, at Self-Serve pay-as-you-go rates of $1.00 per 1,000 credits. On Enterprise plans, credits are $2.00 per 1,000, so the same credit counts cost twice the dollar figures shown. Google: 10,000 elements at $5.00/1,000 (Essentials, no traffic), plus 200 geocodes at $5.00/1,000. Mapbox: 10,000 elements at $2.00/1,000, plus 200 permanent-tier geocodes at $5.00/1,000. Mapbox's cheaper temporary geocoding ($0.75/1,000) is not priced here because its results cannot be stored, and Mapbox's default terms do not permit storing the matrix results either. HERE: 10,000 matrix transactions at about $5.00/1,000, plus 200 geocodes at $0.88/1,000. Free tiers change the picture at small volumes: Google's 10,000 free Essentials elements cover this matrix once per month, Mapbox's 100,000 free elements cover it ten times, and Geocodio's 2,500 free daily credits cover a chunk of any day's run.
Consideration: are you allowed to keep the results?
Two of the providers above price by restriction rather than by calculation, so the headline rate usually buys the restricted version.
Mapbox prices storage. Geocoding costs $0.75 per 1,000 if you agree not to store the results and $5.00 per 1,000 if you want to keep them. For Matrix results, there is no storable tier at any price under the default terms.
Google prices features. The same matrix element costs $5.00 per 1,000 without traffic (Essentials) and $10.00 per 1,000 with it (Pro). The SKU is decided by the request options you set, so a single field can double the bill.
Geocodio prices the calculation. Straightline costs 1 credit per pair and driving costs 2, because routing over the road network takes more compute. Storage, batch processing, and automated queries are not upsells. They are how the product is meant to be used.
When to use each service
Which distance API is the right choice for you depends on your requirements. The storage rules draw the clearest line: if your workflow is data analysis, where results land in a database, a data warehouse, or a report, the providers that prohibit storage are off the table no matter how attractive the rate. If your workflow shows a live result to a user and discards it, those same providers are excellent. Here is the honest sorting.
Geocodio’s Distance API
Use Geocodio’s distance API when:
You are doing data analysis: territory planning, site selection, accessibility studies, or any workflow where distances land in a database or report and get reused, as storage terms are unrestricted.
Your locations are in the US, UK, Canada, or Mexico.
Your data starts as addresses, since geocoding and distance happen in one request, or when you run large or nationwide matrices, batch jobs, and automated pipelines.
You need typical drive times, not real-time conditions or routing
But Geocodio’s distance API probably not a fit when:
Your locations are outside the US, Canada, and Mexico.
You need live-traffic ETAs or turn-by-turn navigation.
Google Routes API
Use the Google Routes API when:
You need to return live results to a user (a delivery ETA on a checkout page, an arrival time in a consumer app). Traffic-aware ETAs (Pro SKU) and global coverage are the strengths.
You are already displaying results on Google Maps and staying inside one ecosystem simplifies your terms compliance.
You need global coverage.
But the Google Routes API is probably not a fit when:
You need to store the results. Data analysis, warehousing distances, and building reports on top of saved results are not permitted uses.
You need to do additional analysis with the coordinates, such as point-in-polygon detection (which is prohibited by Google).
You need to run large matrices: the 625-element cap means many requests.
Cost is a concern. Google’s per-element rates are the highest of any distance API included in this article.
Mapbox Matrix API
Use the Mapbox Matrix API when:
A user taps a map and sees distances in the moment. For live, human-initiated, display-and-discard use, the 100,000 free monthly elements and $2.00/1,000 rate are the best deal on this page, with global coverage.
You are already rendering Mapbox maps and want matrix results in the same SDK.
You don’t need to store the results.
You need global coverage.
But the Mapbox Matrix API is probably not a fit when:
Your workflow is data analysis. The default terms prohibit storing results, and they also bar bulk and automated queries, which rules out batch pipelines and scheduled jobs, not only the saving of output.
Your matrices exceed 25×25, or 10 coordinates for traffic.
HERE Matrix Routing
Use the HERE Matrix Routing API when:
You run very large matrices inside one metro area or region: up to 10,000×10,000 as long as everything fits inside 400 km (about 250 miles). Regional fleet and logistics work with traffic is the sweet spot, and coverage is global.
Results are consumed live and any reuse fits inside the 30-day cache window.
But the Mapbox Matrix API is probably not a fit when:
Your workflow is data analysis that keeps results past 30 days, or when the results feed machine learning or AI systems, which the Platform Terms prohibit.
Your origins and destinations span more than 400 km (about 250 miles), where the cap drops to 15×100 per request.
What Geocodio's Distance API includes
The per-pair credit covers more than a raw number. A few features that usually require post-processing with other providers are built into the request:
Radius limiting. Set a maximum distance (or a minimum, or both) and only destinations inside that band come back. Useful for service-area checks and "within 25 miles" filters without writing your own filtering code.
Nearest mode. Ask for the closest N destinations per origin and skip the rest of the result set. "Find the 3 nearest clinics for each patient" is one parameter, not a sorting job.
Duration filters and sorting. In driving mode, filter by minimum or maximum drive time and sort results by distance or duration, ascending or descending.
Custom IDs. Tag any coordinate with your own identifier (37.7749,-122.4194,warehouse_sf) so results match back to your data without a join step.
Three endpoints for three speeds. A real-time endpoint for single-origin lookups, a synchronous matrix endpoint that returns up to 10,000 calculations immediately, and an async jobs endpoint that processes up to 50,000 calculations and delivers the full result set via webhook.
Distance on geocode calls. Add a destinations parameter to any geocoding request and get coordinates plus the distance to each destination in one response.
Full details and code examples are in the Distance API documentation.
How Geocodio prices distance
Everything on Geocodio runs on one credit system, and a distance request has at most two line items:
Geocoding: 1 credit per address you send. Send coordinates or Stable Address Keys instead and this line item is zero.
Distance: 1 credit per origin-destination pair for straightline, 2 credits per pair for driving distance and time.
For example, a 100 × 10 driving matrix starting from addresses is 110 geocoding credits plus 2,000 distance credits, or 2,110 credits total. Every request's credit usage is visible in your dashboard.
A few details that keep the math friendly:
Credits are fungible. Geocoding, data appends, and distance all draw from the same pool, including the 2,500 free pay-as-you-go credits per day and any Flex subscription credits. And unlike most geocoders, purchased credits don’t expire, and any credits included with your subscription roll over as long as your subscription is active.
Re-runs are cheap by design. Geocode a dataset once, keep the Stable Address Keys, and every future distance analysis on that data pays only for the distance calculations, not geocoding.
Unlimited plans cover the geocoding side. For Unlimited customers, the geocoding component of a distance request runs on their dedicated instance, so credits are only needed for the distance calculations themselves. Annual Unlimited customers also get 25% off distance credit purchases.
Volume discounts apply. Credit bundles from 500,000 up earn 5% to 20% off, and annual subscribers earn additional top-up discounts.
HIPAA-compliant distance calculations
Need to calculate the closest provider to a patient's address, or see which clinics are within a 10-mile radius of each patient? With Geocodio's HIPAA-compliant Enterprise option, you can calculate distances in a HIPAA-compliant manner and we'll sign your BAA. See Enterprise pricing for details.
This information is complete to the best of our knowledge and was verified against provider documents in July 2026. We believe competition is a good and necessary thing, and strive to accurately and fairly describe our competitors. See any mistakes? Please email us.
Related Resources
Geocodio Distance API
Calculate driving distance, driving time, and straightline distance in matrices 5-80x larger than other providers. One-to-one, one-to-many, or many-to-many.
Geocoding Terms of Use Comparison
The same storage and restrictions comparison, applied to geocoding. What each provider's terms allow, with sources, and what the restrictions cost at scale.
Geocodio Pricing
Pay-as-you-go at $1.00 per 1,000 credits with 2,500 free per day, or Flex and Unlimited plans for higher volumes. Distance, geocoding, and data appends all share one credit pool.