Migrating, Comparisons & Security/Licensing FAQ
Choosing a geocoder isn't only a technical decision — engineering leads, security reviewers, and legal teams all need clear answers on accuracy, total cost, permanent data storage rights, customer PII handling, self-hosted SLA ownership, and honest tradeoffs. This guide puts every answer and migration recipe in one place.
Side-by-Side Comparison#
Accuracy numbers below come from our strictly independent 440-query, 9-country, 5-continent Third-Party Global Civic Holdout (report & scripts, zero records sampled from Overture, OSM, OpenAddresses, or GeoNames).
| Dimension | texspace (Serverless) | texspace (Self-Hosted) | Google Maps / Places | Mapbox v6 | Pelias / Geocode Earth | Nominatim |
|---|---|---|---|---|---|---|
| Holdout Top-1 Accuracy | 94.1% (14.3 m p50) | 95.2% (12.7 m p50) | 93.6% (20.9 m) | 87.5% (19.6 m) | 76.6% (23.4 m) | — (55.6% GH6 Messy) |
| Cost per 1M Lookups | ~$0 (static storage) | $0 (single $30/mo VPS) | $5,000 (Places: $2.83–$17/1k) | $750–$5,000 | $500–$1,000 (or 128 GB cluster) | Free (64–128 GB RAM box) |
| Server RAM Required | 0 MB (runs in browser/edge) | 4–16 GB (65 MB idle heap) | Managed API | Managed API | 64–128 GB | 64–128 GB |
| Planet Storage | 8.8 GB (S3 / R2 / CDN) | ~100 GiB NVMe | Managed API | Managed API | 300+ GB | 900 GB–1 TB |
| Setup Time | 0 sec (point to URL) | ~15 min (texspace pull) | API key + billing | API key + billing | 18–48 hrs indexing | 24–72 hrs indexing |
| Permanent Coordinate Storage | Yes (MIT + OSMF Guideline) | Yes (MIT + OSMF Guideline) | Restricted (§3.2.3(a)) | Paid Permanent tier only | Yes | Yes |
| Customer PII Sent to 3rd Party | None (anonymous Range reads) | None (inside your VPC) | Every request logged | Every request logged | None (self-hosted) | None (self-hosted) |
| Custom Polygons & Private Sites | Built-in (enrich, mountGeoJSON) | Built-in (build-overlay) | No (separate stack) | No (separate stack) | No | No |
3-Minute Migration Recipes#
Replace the billed Google Maps Places script + session token management with <texspace-address-input> (or <TexspaceAddressInput /> in React):
<!-- Before: Google Maps Places JS SDK + API key + per-session billing -->
<!-- <script src="https://maps.googleapis.com/maps/api/js?key=AIza...&libraries=places"></script> -->
<!-- After: Zero API keys, $0/mo, zero PII uploaded, auto-fills sibling <form> fields -->
<script type="module" src="https://cdn.jsdelivr.net/npm/texspace/element.js"></script>
<form>
<texspace-address-input name="address1" verify placeholder="Shipping address..."></texspace-address-input>
<input name="address2" autocomplete="shipping address-line2" placeholder="Apt / Suite" />
<input name="city" autocomplete="shipping address-level2" placeholder="City" />
<input name="state" autocomplete="shipping address-level1" placeholder="State" />
<input name="zip" autocomplete="shipping postal-code" placeholder="Postal code" />
<input name="country" autocomplete="shipping country-name" placeholder="Country" />
</form>Swap MapboxGeocoder for TexspaceControl on any MapLibre GL JS map (zero external CSS required):
// Before: Mapbox GL JS + MapboxGeocoder (billed per map load + billed per search)
// map.addControl(new MapboxGeocoder({ accessToken: mapboxgl.accessToken, mapboxgl }));
// After: MapLibre GL JS + TexspaceControl ($0/mo, viewport-biased, click-to-reverse)
import maplibregl from "maplibre-gl";
import { TexspaceControl } from "texspace/maplibre";
map.addControl(
new TexspaceControl("https://shards.texspace.dev/txg/v2", {
maplibre: maplibregl,
reverseOnClick: true,
}),
"top-left"
);texspace serve implements the Pelias GeoJSON v1 contract (/v1/search, /v1/search/structured, /v1/autocomplete, /v1/reverse), so existing Pelias clients switch by changing a single base URL:
# 1. Pull regional or planet shards (~15 min vs. 18–48 hr Elasticsearch build)
texspace pull planet --with-all -o /var/lib/texspace
# 2. Start single-binary server (4–16 GB RAM vs. 64–128 GB Elasticsearch cluster)
texspace serve --db /var/lib/texspace --port 4000 --osm-sync minute
# 3. Point existing Pelias client at your new base URL
curl "http://localhost:4000/v1/search?text=10+Downing+Street+London&size=5"
# Optional: append &format=compact to cut payload size by ~70%Replace multi-day PostgreSQL/Nominatim imports and PostGIS delivery-zone tables with static files or single-binary shards:
# Pack your PostGIS GeoJSON delivery zones / territories once into a static file
texspace pack-layer -i territories.geojson --name territories --id-prop zone_id -o territories.txg
# Upload territories.txg to S3/R2, then enrich coordinates in parallel (zero PostGIS server)import { Texspace } from "texspace";
const geo = await Texspace.open("https://shards.texspace.dev/txg/v2");
const res = await geo.enrich(37.43296, -122.1291, {
reverse: true,
timezone: true,
layers: ["https://cdn.example.com/territories.txg"],
});Security, Privacy & Legal FAQ#
Can we legally store geocoded coordinates permanently in our database?#
Yes. Unlike Google Maps Platform (§3.2.3(a)) and standard Mapbox plans, texspace imposes zero restrictions on storing or caching coordinates, standardized addresses, parcel APNs, or timezones in your own database or data warehouse:
- Source code: MIT License — permissive commercial use with zero copyleft requirements.
- Open data & ODbL clarity: Pre-built shards combine Overture Maps (
CDLA-Permissive-2.0/ODbL-1.0), OpenStreetMap (ODbL-1.0), Public Domain national address registries (USDOT NAD, StatCan, G-NAF, Cadastre Etalab), and GeoNames (CC-BY-4.0). Under the official OpenStreetMap Foundation Geocoding Guideline, geocoding outputs (coordinates linked to your own customer or order records) constitute a Collective Database / Produced Work — storing geocoded results in your proprietary database does not trigger ODbL share-alike obligations on your customer data. - Required attribution: Include a standard data attribution line on maps or about/credits pages (see
ATTRIBUTION.md):
Geocoding powered by texspace. Data © OpenStreetMap contributors (ODbL), Overture Maps Foundation, and public civic address registries.Does any customer PII leave the browser or our VPC?#
No — verifiable in DevTools.
- Serverless browser / edge mode: Your customer's street address, apartment number, or CSV row is tokenized and matched strictly inside local WebAssembly RAM. The browser only fetches anonymous
16–32 KBcompressed byte slices (HTTP 206 Partial Content) from static.txgarchives — no street address, customer name, or search string ever appears in any URL, query parameter, header, or request body. - Self-hosted / DuckDB / Mobile mode: Runs 100% locally inside your VPC, data warehouse, or on-device storage with zero outbound calls.
Should we depend on shards.texspace.dev in production, or host the files ourselves?#
- Prototypes, dev environments & low/medium traffic:
https://shards.texspace.dev/txg/v2is free, CORS-enabled, and cached on Cloudflare's global edge network. - High-volume or SLA-critical production (recommended): Mirror the immutable 8.8 GB static files into your own AWS S3, Cloudflare R2, or GCS bucket (or pull just the single state/country shard you need — e.g.
us_ca.txgis ~350 MB). On Cloudflare R2, hosting the entire planet costs ~$0.13/month with $0 egress fees, completely under your own AWS/Cloudflare account, IAM policies, and uptime SLA. See Hosting, Caching & Self-Hosting for exact CORS headers and Cloudflare Worker R2 bindings.
How fresh is the geographic data?#
- Monthly planet releases: Updated
.txgand SQLite shards are published monthly with SHA-256 manifests (texspace update --db <dir>performs incremental atomic upgrades). - Minutely live OpenStreetMap sync (self-hosted): Run
texspace serve --db <dir> --osm-sync minuteto stream official OpenStreetMap.osc.gzdiffs with zero-downtime hot reload. - Instant private additions: Add newly built subdivisions, private depots, or temporary venues immediately via
geo.mountGeoJSON()ortexspace pack-overlay.
Honest Tradeoffs: When to Use texspace vs. Commercial APIs#
We want you to adopt texspace where it genuinely wins:
- Where
texspaceexcels: Street addresses, rooftop & cadastral parcel precision, checkout autofill & verification, private store/warehouse locators, custom territory point-in-polygon enrichment, private HIPAA/GDPR batch CSV & DuckDB pipelines, AI agent grounding, offline iOS/Android mobile apps, and low-RAM self-hosting. - Where Google Maps / Foursquare / Mapbox still lead: Long-tail commercial business directories (small-business phone numbers, user star ratings, photos, real-time restaurant opening hours, and newly opened storefronts not yet mapped in Overture/OSM). If your product is a Yelp-style restaurant review finder, pair a commercial POI directory with
texspacefor address/territory workloads.
Next Steps#
- 5-Minute Quickstart — Test
texspaceagainst your own addresses right now. - Hosting, Caching & Self-Hosting — Mirror to your own S3/R2 bucket or deploy
texspace servein Docker/systemd. - Checkout & Address Verification — Includes an interactive Google Places / Mapbox monthly cost calculator at texspace.dev/checkout.