GeoJSON to TopoJSON Converter
Compress spatial geometries by consolidating shared boundary lines.
Reduce file sizes for complex web layers. This upcoming tool compresses bulky GeoJSON files into lightweight TopoJSON models by identifying and consolidating shared coordinate lines.
Drag file here to convert, or select file
Supported file extension: .geojson, .json • Max 50MB
Specification Rules
- Optimize heavy vector layers to speed up web dashboard loading speeds
- Compress municipal boundaries before distributing map files online
- Translate geospatial data for mobile-first web applications
- Standard desktop GIS clients may require extensions to parse the format
- Simplification can lead to spatial changes if parameters are set too high
- Deeply nested metadata structures are difficult to translate directly
GDAL Direct Equivalent Terminal Command
When to use this conversion
Convert when a GeoJSON dataset with many adjacent polygons (electoral districts, country borders, watershed basins) needs to be served as compactly as possible. TopoJSON encodes shared boundaries once, cutting file size by 60–80% for these cases.
Technical Details
TopoJSON is typically 20–40% the size of the source GeoJSON for datasets with adjacent polygons. For point or disconnected polygon data, the ratio is near 1.
Common Errors & Fixes
- No size savings: the dataset has no shared boundaries (points, disconnected polygons). Fix: don't use TopoJSON for that data; stick with GeoJSON.
- Quantisation too aggressive: boundaries become visibly jagged. Fix: increase the quantisation factor (1e6 instead of 1e4).
- Properties dropped: some converters strip non-essential properties. Fix: check the source command's flags and re-run with property preservation enabled.
- Web library can't consume: Leaflet doesn't read TopoJSON directly. Fix: decode in the browser with topojson-client.feature() before passing to L.geoJSON.
Alternative Tools
- topojson-server (npm): geo2topo input.geojson -o output.topojson
- mapshaper CLI: mapshaper input.geojson -o output.topojson
- mapshaper.org web app for in-browser conversion
- D3 ecosystem tutorials: bl.ocks.org examples often include topojson scripts
Frequently Asked Questions
How much can I reduce file sizes?
This compression can reduce files up to 80% by consolidating shared boundaries and simplifying line segments.
Does this tool support simplifying boundary details?
Yes, our upcoming interface will offer options to adjust simplification levels to match your needs.
Can I convert shape structures directly?
Convert GIS shapefields to GeoJSON first, then compress them directly into lightweight formats.