Is it possible to convert a shapefile to a gml file? If so, how and using what tools?

1 Answer 1


Yes, using the command line ogr2ogr tool.

For example, given a "roads.shp" file, you could convert it using the following:

ogr2ogr -f GML roads.gml roads.shp

ogr2ogr provides a large array of options, so you might want to review them prior to executing. You can also use the tool to create only a subset of the input data and also reproject the output.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.