Tile38
activeby Josh Baker (tidwall) · since 2016
In-memory geospatial database and geofencing server that speaks the Redis protocol and HTTP.
Overview
Tile38 is Josh Baker's (tidwall) open-source geolocation store: it keeps points, bounding boxes, geohashes, XYZ tiles and full GeoJSON objects in memory with spatial indexes, persists to disk, and answers nearby, within and intersects queries with field filters. Its standout feature is real-time geofencing: you register fences and it pushes enter, exit and cross events over pub/sub channels or webhooks to HTTP, gRPC, Kafka, AMQP, MQTT, NATS, SQS and other endpoints. Clients connect over the Redis RESP protocol, HTTP, WebSockets or telnet, and leader/follower replication adds read replicas and standby copies. Version 1.38.0 shipped in June 2026, and it remains the go-to choice when you need fast moving-object queries without a full GIS database.
Strengths & trade-offs
Strengths
- +Real-time geofencing with enter, exit and cross events
- +Webhooks to HTTP, gRPC, Kafka, MQTT, NATS, SQS and more without glue code
- +Works with any Redis client over RESP, or plain HTTP
- +Fast in-memory spatial queries on points, boxes, tiles and GeoJSON
- +Single Go binary, MIT licensed and actively maintained
Trade-offs
- −Dataset must fit in RAM on one leader
- −No sharding or multi-leader writes
- −Not a full GIS: no projections, rasters or SQL spatial functions
Great for
- +Fleet, courier and ride-hailing vehicle tracking
- +Geofence alerts for IoT devices
- +Location-based notifications in mobile apps
- +Real-time nearby search for moving objects
Think twice for
- −Complex GIS analysis (use PostGIS)
- −Datasets larger than memory
- −Transactional business data
Capabilities
Native or official first-party support · 6 of 25 tracked
Scale & consistency
- Comfortable data size
- Medium · ≤ 10 TB
- Horizontal scaling
- Manual
- Multi-region
- No
- Transactions
- None
- Consistency
- Eventual
- Schema
- Schemaless
- Architecture
- In memory, Primary replica, Client server
- Query languages
- Tile38 commands
Dataset must fit in one leader's memory; followers add read capacity and standby copies.
Deployment
Ecosystem
Alternatives to Tile38
The standard spatial extension for PostgreSQL: geometry, geography, rasters and topology in SQL.
tile38 vs postgis →The in-memory data structure server that became the default cache, now with search, JSON and vectors built in.
tile38 vs redis →The Linux Foundation's BSD-licensed fork of Redis, now the default engine on AWS and Google Cloud.
tile38 vs valkey →The default document database: flexible BSON documents, rich queries and built-in sharding.
tile38 vs mongodb →Lucene-based distributed search and analytics engine for text, vectors, logs and metrics.
tile38 vs elasticsearch →Flash-optimized distributed key-value and document database for predictable sub-millisecond latency at scale.
tile38 vs aerospike →Tile38 FAQ
What is Tile38?
Tile38 is a spatial database by Josh Baker (tidwall), first released in 2016. Tile38 is Josh Baker's (tidwall) open-source geolocation store: it keeps points, bounding boxes, geohashes, XYZ tiles and full GeoJSON objects in memory with spatial indexes, persists to disk, and answers nearby, within and intersects queries with field filters. Its standout feature is real-time geofencing: you register fences and it pushes enter, exit and cross events over pub/sub channels or webhooks to HTTP, gRPC, Kafka, AMQP, MQTT, NATS, SQS and other endpoints. Clients connect over the Redis RESP protocol, HTTP, WebSockets or telnet, and leader/follower replication adds read replicas and standby copies. Version 1.38.0 shipped in June 2026, and it remains the go-to choice when you need fast moving-object queries without a full GIS database.
Is Tile38 open source?
Yes. Tile38 is open source. License: MIT License.
Does Tile38 support ACID transactions?
No. Tile38 does not provide ACID transactions; its consistency model is eventual.
Does Tile38 scale horizontally?
Tile38 has no built-in sharding; scaling out means partitioning data in your application. It is comfortable at medium scale (≤ 10 TB).
How can I run Tile38?
You can self-host it.
What is Tile38 best for?
Tile38 is a strong fit for fleet, courier and ride-hailing vehicle tracking; geofence alerts for IoT devices; and location-based notifications in mobile apps. Think twice for complex GIS analysis (use PostGIS).
What are the best alternatives to Tile38?
Common alternatives to Tile38 include PostGIS, Redis, Valkey, MongoDB and Elasticsearch. The right choice depends on your workload, scale and hosting; WhichDB's smart match ranks them against your requirements.
How popular is Tile38?
Tile38 ranks #305 of 844 databases on the WhichDB Score (10.0/100), and #2 among spatial databases. The score combines public adoption signals such as package downloads, GitHub activity, job posts and developer discussion.



