Convert GEOJSON to GML

Turn GEOJSON files into GML. A GML 3.2 document with one feature type holding the features and their attributes, in the source's coordinate system and without a separate schema file.

Converted in an isolated sandbox on our serversDeleted after 24 hours

Drop GEOJSON files on the dialor turn it to pick what to do

GeoJSON as a GML 3.2 document.One file with your features and their attributes, ready for tools that read GML.

  1. What you get

    A GML 3.2 document. It holds one feature type, and the features from your GeoJSON are listed under it with their attributes.

    The coordinates stay in the source's coordinate system. No separate schema file is written, so the output is the one GML file and nothing else.

  2. What changes

    Heights are handled per feature. When some features have heights and others do not, the ones without get a height of 0.

    Attributes that are lists or nested values become JSON text. The value is kept, but it is stored as a string in the GML, not as a structure.

  3. Going the other way

    To turn a GML file back into GeoJSON, use GML to GEOJSON. To combine several GeoJSON files first, use merge GEOJSON.

GEOJSON and GML.What each format is.

The formats

From · GEOJSON

GeoJSON

Points, lines and polygons as JSON, the web's map data format.

Extensions
.geojson
MIME type
application/geo+json
Kind
Text and data
To · GML

GML

Geography Markup Language, the OGC's XML for map features, as WFS services send it.

Extensions
.gml
MIME type
application/gml+xml
Kind
Text and data

In your code.The same GEOJSON to GML conversion through the API, for your app or your agent.

terminal
$ cv convert report.geojson report.gml
$ cv convert report.geojson report.gml

Questions.What people ask about GEOJSON to GML.

01OF 04

GML 3.2. The document has one feature type that holds all the features.

No. The output is a single GML file without a separate schema file.

If some features have heights and others do not, the ones without get a height of 0.

They become JSON text. The value is kept as a string in the GML.

More conversions.Other ways in and out of GEOJSON and GML.