Sign up ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I have been tasked with getting OS Mastermap topography data into QGIS system to compliment our other map layers. The data comes in .gz format. Which I am told needs to be decompressed before I can do anything further? After decompressing it using WINRAR it turns it into a file which has no file type? I assume it is supposed to be .gml?

I have read I then need to convert it into shape file format so that QGIS can read it, so I use OS GML to OGR python plug in. Which seems to do nothing...or says "processing stage failed with code 1". Can anyone give me any advice or a brief walkthrough on how to get OS Mastermap data into QGIS?


share|improve this question
Mastermap is in GML format - but delivered in compressed format. –  Mapperz Aug 15 '12 at 14:59

8 Answers 8

I just tried it with the sample data from here:

The QGIS import plugin asks for compressed files (*.gz), so just start it up, define input and output folders, choose your output format, and press "convert". It should work right away.

EDIT: The file within the *.gz frome the example I linked doesn't have an extension either, but I opened it with a text editor and it does contain GML syntax.

share|improve this answer
Yeah that worked fine, although the formatting and colours are all over the place. How would you do the same thing if you had 4 different folders with a number of .gz files in each? –  Adam Aug 15 '12 at 14:52
I'm not too familiar with GML and have no knowledge on Mastermap data, but I suppose it's just like any pure vector data (like shape) and thus doesn't contain any styling by default - that would be your job (maybe there are some pre-defined stylings in the web somewhere?). Also, QGIS can copy-paste styles from one layer to another, that might be handy. Regarding the multiple folders: As far as it looks, the GML plugin converts ALL *.gz files within the input folder and puts them in accordingly named output subfolders, so you just would have to run the process four times? –  SAnderka Aug 15 '12 at 15:00

You really need to know the type of the file before it was compressed (and I'm afraid I'm not familiar with how OS MasterMap files are distributed).

You might find the uncompressed file is already a shapefile and so can be easily opened in QGIS. Why not try adding the .shp extension to the uncompressed file and trying to open it in QGIS?

share|improve this answer
It is GML. Unzip the file, and add the .gml to the end. Can be opened no problem in QGIS. –  Vesanto Mar 25 at 11:33

To convert the MasterMap files use this free software 'OSM2MIF' from Oxford Boleian Library Map Room.

You can load the tab files into QGIS after conversion.

MasterMap is in GML format. Versions of MapInfo prior to v 8.0 do not support the full import of OS gml. OSM2MIF translates MasterMap data files into MapInfo MIF (MapInfo Interchange Format). MIF files can then be imported and opened in MapInfo. Once the files have been imported, they are saved as MapInfo tables (.tab files).

Features: OSM2MIF translates all three layers (topographic, address and ITN). Attribute data is maintained (currently not all routing data in the ITN layer is supported, but this may be improved in a later release). Update versions of MasterMap include Departed Members and a list of these can be extracted using OSM2MIF. Single or batch file processing is possible.

useful information on

share|improve this answer

I have found the OS GML Tools plugin to be a bit strange when I specify the same input and output directories. Try specifying different input and output directories (I usually create folder called gml and one called shp and use those.

The file that has no extension can be renamed to .gml and it will be fine.

Their is a guide on this website on how to use the OS GML Tools plugin.

In terms of styling you can download QGIS qml files from that site as well (direct download links included below):

For lines:

For areas:

share|improve this answer

Faunalia provide a plugin to handle OS Mapping. The plugin is available in the Faunalia Repository.

To add Faunalia repository: From the main menu, select Plugins > Fetch Python Plugins A new window will appear. Select Repositories tab, and then click on Add ... A new window will appear again. For name, type: Faunalia Repository and for URL:

Hope this helps Nige

share|improve this answer
Sorry. Plugin is called OS Translator. –  Nigel Law Aug 15 '12 at 18:51

I just tested it and you can just drag and drop the compressed gml into QGIS and then choose which layer to import. Works fine with Quantum GIS 1.8 Lisboa.

share|improve this answer

I maintain which the Lutra QGIS plugin uses under the hood to do the translation. Loader is a command line application that allows you to translate KML and GML data (optionally compressed) in to one of the many formats supported by OGR (Shape, MapInfo Tab, PostGIS, SQL Server etc.).

Install instructions and usages examples are available on the project wiki including instructions for loading data suitable for QGIS. Installation and configuration is more involved than the QGIS plugin but it provides greater flexibility.

Currently configuration is provided for the following Ordnance Survey products:

  • AddressBase Plus
  • AddressBase Standard
  • OS MasterMap ITN
  • OS MasterMap Topography
  • VectorMap Local
share|improve this answer

We have a new tool which you can load large number of Ordnance Survey's MasterMap into PostGIS. The tool is written from scratch and is pretty fast compared with others:

share|improve this answer
Welcome to gis.stackexchange! While we do not forbid advertising products which solve the specific problem described in a thread, it is generally recommended to provide specific details and - if appropriate - code/screenshots to back up your claims rather than a couple of links to some product website. –  underdark Mar 25 at 13:11
This is a free and open source plugin for qgis, so not much of an advertisement. All the description and steps required are within the links and I avoided duplication. –  Lutra Mar 31 at 8:07
This is in fact legit. –  shongololo Jun 20 at 18:49

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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