[Update: there is a nice working plugin that does the trick, see here]
In GIMP exporting multiple layers to one pdf file is surprisingly difficult. I found two solution, both require additional software besides GIMP, but are fairly easy to implement. One solution is given here. [this link doesn't work anymore] It requires a plug-in or script to export individual layers to separate tiff files (something which perhaps surprisingly is not possible out-of-the-box in GIMP).
The before-mentioned site suggest the script “Save Layers as Individual Files”, which can be downloaded [this link doesn't work anymore] from Panotools. Next step is to use ImageMagick to convert the tiff files into a single pdf file. Unfortunately the script throws up an error when I try to open it.
Luckily I found an even easier solution here. No need for a separate plugin, but you still need GraphicsMagick or ImageMagick.
- Open the GIMP file with multiple layers
- Make sure to order the layers in reverse order, page 1 must by the bottom layer, the last page the top layer
- Save the file as a MNG animation. In the dialogue that comes up, select “save as animation”.
- Now, open the terminal and use the command ‘convert document.mng document.pdf’ to export the mng file to a pdf file.
Credits go to Patrick’s WebLog, go there for more details.

You can also, if you like the way GIMP orders the layers, use the “-reverse” switch in ImageMagick (eg “convert document.mng -reverse document.pdf”), though GIMP does have Layer > Stack > Reverse Layer Order.
The MNG tip is a good one, as ImageMagick only supports the bottom two layers of an XCF, and for some reason repeats page 1 at the end of the PDF when converting from PSD. GIF works perfectly, but of course has colour restrictions. Thanks for that!
Thanks for the tip about using the ‘-reverse’ switch in ImageMagick or alternatively the ‘reverse layer order’ option in GIMP
Don’t know if you’re interested, but I found out you can actually get around the PSD problem (of having a repeated bottom layer) by specifying what layers to convert, making the command “convert document.psd[1-*numberOfLayers*] document.pdf”, which in my case was “convert document.psd[1-4] document.pdf”. This works pretty well for me, because I’m pretty happy to work on the file in GIMP as a PSD.
http://www.imagemagick.org/discourse-server/viewtopic.php?f=3&t=16498
Great stuff! Worked like a charm. Thanks a bunch!
Alex
There is even simpler fix that worked for me. I have just merged all layers to one (in layers command right click and then merge down, gimp 2.8.0). With one layer left I have exported to pdf and it worked great.
But wouldn’t that leave you with a pdf with one page (the merged image) only? I see I did not mention it explicitly, but what I was trying is to get a pdf with one page per layer.
I’ve been trying to figure this out forever. Worked great, thanks!
Hi,
Also try this script. PDF straight from Gimp
http://registry.gimp.org/node/25677
Great, thanks for pointing out. I tried it out and it works like a charm (I wrote a new post about it here: http://pvanb.wordpress.com/2013/03/08/a-plugin-to-export-layers-in-gimp-file-to-single-pdf-file/)
Pingback: A plugin to export layers in GIMP file to single pdf file | Ecostudies
Thank, its work