Black background being added to transparent PNGs on resize

Hey guys,
I’ve got an issue that I just can’t figure out. I’ve just finished and launched a Kirby site in which I’m resizing pngs with transparent backgrounds, uploaded by the user using the built in resize object.

This was working fine on our staging server running php 7.1 but when we’ve uploaded the site to the live server (php 7.3) the resized images all have black backgrounds baked in to them. To try and diagnose I’ve changed our staging server to php 7.3 and this has the same affect — black backgrounds start showing up.

Here’s a screenshot of the gd settings on the live server for reference.

Has anyone else noticed this happening? Any help would be much appreciated!


The issue was already reported here: Crop Function PNG render Issue. Might have to do with the GD version, see the linked Simpleimage issue. Try switching to ImageMagick if available on your server.

Unfortunately, the TO hasn’t reported if they found a solution.

Thanks @texnixe switching to ImageMagick has solved the issue!

Thanks for reporting back, @jackfowler