GeoJSONB (Binary GeoJSON)
Nov 24,2025
GISBox is a one-stop 3D GIS data editing, conversion and publishing platform that supports editing in multiple GIS formats such as OSGB/GEOTIFF/RVT, converting to 3DTiles/Terrain and publishing.
Introduction
GeoJSONB is a binary format used in PostgreSQL databases for storing GeoJSON data. It enables the database to handle geospatial data in a more compact and efficient manner. This format is supported by the PostGIS extension for PostgreSQL, which is a specialized geospatial database extension designed to enhance PostgreSQL's capabilities in managing location-based information.

File Structure
GeoJSONB (Binary GeoJSON) primarily consists of the following structural components:
- Basic Structure: Includes a type field (required, specifies the object type), a coordinates field (stores coordinate data), and a properties field (optional, stores attributes).
- Object Types: Supports geometric objects (e.g., Point, LineString, Polygon), feature objects (Feature, containing geometry and attributes), and feature collections (FeatureCollection, comprising multiple Features).
- Optional Fields: May include bbox (bounding box array) and crs (coordinate reference system information).
Pros
- Efficient Storage and Transmission: By utilizing binary encoding, it significantly reduces storage requirements and network transmission overhead compared to text-based GeoJSON, making it suitable for large-scale data scenarios.
- Full Compatibility: Maintains complete compatibility with all standard GeoJSON object types (e.g., Point, Polygon) and structural elements (such as type and coordinates fields).
- Lightweight and User-Friendly: Built on JSON's clear structure, it remains easy to read and write, allowing developers to quickly adopt and implement the format.
- Extensive Ecosystem Support: Enjoys native support from mainstream GIS tools (e.g., GeoServer, OpenLayers) and databases (such as PostgreSQL's jsonb type).
Cons
- Data Volume Concerns: Despite binary compression, complex geometric data (e.g., polyhedrons) may still result in substantial file sizes, impacting transmission efficiency.
- Computational and Scalability Constraints: The format is unsuitable for large-scale distributed computing and often requires specialized tools (e.g., Hologres) to optimize performance.
- Parsing Complexity: Binary data necessitates dedicated parsing libraries, increasing development overhead, while query performance in certain scenarios may lag behind structured formats like Shapefile.
Application Scenario
GeoJSONB (Binary GeoJSON), as an efficient geospatial data encoding format, finds extensive application across multiple domains. It is widely used in web mapping services (e.g., Leaflet, Mapbox) to support the visualization and interaction of geographic data such as points, lines, and polygons, making it particularly suitable for rapid rendering of small to medium-scale datasets. In 3D mapping development, GeoJSONB can store complex geometric shapes (e.g., polyhedrons) and enable 3D visualizations, commonly applied in urban modeling or terrain representation.
As an open standard, it also serves as a universal format for geodata exchange, facilitating seamless data sharing between GIS tools like QGIS and PostGIS.
Moreover, its binary encoding特性 makes it well-suited for real-time attribute updates (e.g., traffic monitoring, location tracking), reducing transmission overhead and enhancing the efficiency of dynamic data processing.
For mobile or embedded applications requiring lightweight storage, GeoJSONB is also an ideal choice.
Example
- Convert GIS data GeoJSON into a 3D city model file OBJ.
File Opening Mode
- Preview the GeoJSON file using VSCode.
Related GIS files
HDF
STYL
MXD
SL3
References
- https://en.wikipedia.org/wiki/GeoJSON
- https://geojson.org/
- https://gdal.org/en/stable/drivers/vector/geojson.html