I georeferenced a raster file and ended up with black background (exact 000000) The raster file contains a lot of blacks, so setting black to be a transparent color is not a good solution since I would lose the details on the raster file.

I have seen several similar questions from a few years ago. None of the answers is straightforward and works in my case. Hoping there is a better solution in more recent QGIS versions.


For me the best method is to edit the file in Photoshop (or other editor). Double click on background layer and make it a general layer. Then I select the one pixel in the right lower corner and delete this pixel, it will turn transparent. Then I save the file as TIFF with zip-compression, no layers with transparency on. Then when you Georeference the borders will be transparent.

save in photoshop


Thank you Michael, this answered helped

Here are the detailled steps I took. If someone is not an export in QGIS, it might help.

  • Upload raster in QGIS
  • Apply relevant CRS
  • Add transparent no data value to raster (e.g. -333333)
  • Save as Geotiff
  • Open the Geotiff in the Georeferencer (Do not check use 0 for transparency)
  • In raster properties (add no value e.g. -333333) -Run the georeferencer and you should end up with clean file with a transparent background instead of the black background

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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