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.

In my project, I use a lot of geodata from different directories. Now I want to give the QGIS project to a colleague (eg on a CD).

Is it possible to copy the shapes from different directories automatically to one directory?

share|improve this question

3 Answers 3

There is now also the new relocator plugin. (marked as experimental as well at this moment). Gives you the opportunity to save all layers with the project file into one directory or even in a zip-file.

share|improve this answer

You're looking for the QConsolidate plugin, which works very well. It will transfer everything to a single directory and rewrite the .QGS project file (an XML file) to point to the new source locations.

EDIT 2015-02-22

QConsolidate is still listed as experimental - you'll have to enable "Show also experimental plugins" in the settings dialog.

However - it works very well. Notes:

  • You must have saved the project you're working on before attempting to consolidate it elsewhere;
  • The output format will be the project (.QGS) file, together with a folder called 'layers' that (surprise!) contains the layers;
  • QConsolidate will convert database layers into shapefiles and rewrite the project file to refer to the new shapefile;
  • While often you may want to share the consolidated project on an external / thumb drive, save it on a local hard drive first as the many write operations made will really slow things down if you try to consolidate directly onto slow media.
share|improve this answer
Thank you very much. QConsolidate is exactly what I was looking for. – Hendrik Pehlke Sep 13 '12 at 8:43
@HendrikPehlke You might want to accept his answer. Just click the check mark :) – R.K. Sep 18 '12 at 17:56
Just looked for an answer for the same problem. I guess with the Qconsolidate and relocator plugins the topic can be seen as anwered. BUT: I really hope the development of relocator picks up because QConsolidate seems to be almost dead :( Not a single commit in 2 years on the github page. – martin Jul 10 at 20:02

I don't know about a way in QGIS itself, but the project file (.qgs) is just a text file. Therefore a primitive but effective way would be to copy everything manually into one directory, then alter the <datasource></datasource> tags in the .qgs file either using find and replace or a regular expression to point to the new directory.

If you've got a lot of different files/directories, one option would be to automate it in python by searching for each tag in the .qgs file, copying each related file with that name to a directory, and then replacing the .qgs tag with the new directory.

share|improve this answer

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.