Solution – Call to undefined function imagecreatefromjpeg()

If you are receiving following error message when uploading image via any script (WordPress / Drupal / Joomla / prestashop etc.)

Fatal error: Call to undefined function imagecreatefromjpeg() in /home/…/..

This means your server do not have GD Library installed.

Solution for cPanel Server

If you have root access to server, and you are on a cPanel server, you can install GD from EasyApache from:

WHM Home >> Software >> EasyApache (Apache Update)

Re-run EasyApache and select GD

Solution for non-cPanel server

If you are not on a cPanel server, here is how you can install GD library.
Login to your server as root via SSH and run following command

yum install php-gd
service httpd restart


yum install gd gd-devel php-gd
service httpd restart


I don’t have root access of server

If you are on a shared hosting or if you do not have root access of server, please contact your hosting provider to enable / install GD library on the server.

Our Recommended Hosting

Leave us a Reply

Your email address will not be published. Required fields are marked *

* *