WKB 🧮

Well-Known Binary (OGC)

Open Beta
.wkb · application/vnd.ogc.wkb

WKB (Well-Known Binary) is the binary representation of vector geometry from the OGC Simple Features standard (1999), the foundation of nearly every GIS database: every geometry in PostGIS, MySQL Spatial, GeoPackage is WKB under the hood. The format is several times more compact than text WKT by packing coordinates into doubles without ASCII. Our exporter writes the geometries of the selected OSM layers into a .wkb file: each individual feature is standard OGC WKB, but the file is a container — an 8-byte header (magic WKB\x01 + feature count), then length-prefixed geometries, with the coordinate system in a companion .prj file. Honestly: parsing the file requires reading the header and the length prefixes — it is not a single «bare» blob for a direct ST_GeomFromWKB. Multiple layers are packed into a ZIP.

Export WKB now ✨ Open Beta — free, no limits

Key Features

Each feature's geometry is standard OGC WKB
Container: an 8-byte header + length-prefixed geometries
Coordinate system in a companion .prj (WKT) file
Several times more compact than text WKT (doubles without ASCII)
Single layer — a .wkb file, multiple layers — a ZIP archive

What Program Opens WKB Files

The following programs and applications can open, edit, and work with Well-Known Binary (OGC) (.wkb) files exported from OSM2CDR:

💻PostGIS 💻Shapely (Python) 💻GDAL/OGR 💻JTS / GEOS 🌎QGIS

Format specifications

Who Uses WKB Maps

🏗
Building a custom GIS pipeline on Shapely, JTS, or GEOS without parsing GeoJSON
💻
Loading geometry into PostGIS or MySQL after parsing the container header
📊
Checking your implementation against the OGC Simple Features standard
🎨
Compact geometry transfer between services as a binary exchange

How to Export WKB

1
Select area
Draw a rectangle or polygon on the interactive map at osm2cdr
2
Choose WKB
Select Well-Known Binary (OGC) from the list of 127 available export formats
3
Export
Click Export and receive your .wkb file in 1-5 minutes
4
Download
Download the ready WKB file and open it in PostGIS

Popular maps in WKB

Free

Get Well-Known Binary (OGC) map exports

Download professional WKB maps from OpenStreetMap. Instant generation, any area.

Free / export
Export WKB now →

Frequently Asked Questions

Can I INSERT it directly via ST_GeomFromWKB?
Where is the coordinate system stored?
How does WKB differ from WKT?
How do I read WKB in Python?

Related Formats

Frequently Exported Together

Related Articles