Friday, October 24, 2025
HomeLanguagesHow to Install ImageMagick and Imagick PHP extension in Ubuntu?

How to Install ImageMagick and Imagick PHP extension in Ubuntu?

The Imagick function is used to create and modify images using the ImageMagick API. The ImageMagick is the software suite to create edit and modify the compose bitmap images. This functions read, write and converts images in many formats including DPX, EXR, GIF, JPEG, JPEG-2000, PDF, PhotoCD, PNG, Postscript, SVG, and TIFF.

Requirements: PHP 5.1.3 and ImageMagick 6.2.4 versions required to install ImageMagick.

The installation process of ImageMagick (Imagick) on Ubuntu: There are some steps to install ImageMagick and Imagick PHP extension on Ubuntu 16.04, 18.04 and above versions which are listed below:

  • Install Apache Server: If apache server is not installed in your system then first install the apache2 server.
  • Make Superuser: Open terminal and use following command to make yourself superuser.
    sudo su

  • Install Required Packages: Use the following command to Install the required packages of ImageMagick and Imagick PHP extension.
    $ sudo apt install php php-common gcc

  • Install ImageMagick extension: Now install the ImageMagick PHP extension by using the following command.
    $ sudo apt install imagemagick

  • Install Imagick extension: After completion of ImageMagick package, the Imagick PHP extension will install.
    $ sudo apt install php-imagick

  • Restart Apache Server: Restart the apache server by using the following command.
    $ sudo systemctl restart apache2

  • Verify the Imagick extension: The Imagick extension can be verified by using the following command.
    $ php -m | grep imagick

RELATED ARTICLES

Most Popular

Dominic
32361 POSTS0 COMMENTS
Milvus
88 POSTS0 COMMENTS
Nango Kala
6728 POSTS0 COMMENTS
Nicole Veronica
11892 POSTS0 COMMENTS
Nokonwaba Nkukhwana
11954 POSTS0 COMMENTS
Shaida Kate Naidoo
6852 POSTS0 COMMENTS
Ted Musemwa
7113 POSTS0 COMMENTS
Thapelo Manthata
6805 POSTS0 COMMENTS
Umr Jansen
6801 POSTS0 COMMENTS