What is your image driver on localhost and what on the server.
I recommend to you use imagick as driver in the both cases.
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
Hi, I am using image Intervention to save images and resize them. I discovered this error when trying to use my same code on my server. It worked fine locally but errored out on the server. Following instructions online I changed my memory_limit = -1 and that seemed to work. However, just today I started getting the same error in my logs
[2020-07-02 18:18:14] production.ERROR: Unsupported image type. GD driver is only able to decode JPG, PNG, GIF or WebP files. {"userId":1,"exception":"[object] (Intervention\Image\Exception\NotReadableException(code: 0): Unsupported image type. GD driver is only able to decode JPG, PNG, GIF or WebP files. at /var/www/html/ei/vendor/intervention/image/src/Intervention/Image/Gd/Decoder.php:59)
[stacktrace]
I haven't changed any of the code and I checked the memory_limit is still -1. I am currently downloading a lot of data so I thought maybe that could be causing it, but I still don't want other users to experience this if they have limited bandwidth as well. I timed how long after I tried uploading I got the 500 error and it was 6 seconds. So I tried changing my max_execution_time = -1 and max_input_time = 60 but it still errors out after 6 seconds which seems strange to me. Can anyone see anything I am missing? I am currently trying with a 5.7 mb image file that works fine when I try to upload to my local. If I try to use a smaller image around 200k that also works fine on my server. It is only when I try to upload the big image to my server.
What is your image driver on localhost and what on the server.
I recommend to you use imagick as driver in the both cases.
Please or to participate in this conversation.