geolith search is a geocoding API written in Rust. It answers forward geocoding, autocomplete, structured address search and reverse geocoding over the places and addresses that geolith builds from Overture Maps and OpenStreetMap. Every endpoint answers from one .glx file.
- Hosted or self-hosted. Call the same API at
https://api.geolith.app with a key (Hosted API), or run it yourself. - One file. All data is in one
.glx file. A .glx file is to geocoding what a .pmtiles archive is to tiles: geolith search serves it as tileserver-rs serves .pmtiles. There is no database and no Elasticsearch cluster. - Ranked in the index. Results are ordered by BM25 text relevance plus the importance of each place. Filters apply before place records are read.
- Safe input. User text is split into words before it reaches the index, so it has no query syntax. Search text is never written to the logs.
| Project | Role | Status |
|---|
| geolith | Builds planet basemaps and the .glx geocoding file | Live |
| tileserver-rs | Serves vector and raster tiles, styles and fonts | Live |
| geolith search | Geocoding, autocomplete and reverse geocoding | Live: hosted at api.geolith.app and self-hosted |
| Routing on Valhalla | Turn-by-turn routing | Roadmap |
| Endpoint | Purpose |
|---|
GET /v1/search | Forward geocoding from free text |
GET /v1/autocomplete | Search as you type |
GET /v1/search/structured | Geocoding from separate address fields |
GET /v1/reverse | Places nearest to a point |
GET /health | Reports that the server runs and how many places it serves |
GET /openapi.json | OpenAPI 3.1 document |
GET /docs | Interactive API reference (Scalar) |