How to Install ImageMagick on Ubuntu 20.04

Imagemagick-logo

In this article, we will have explained the necessary steps to install and configure ImageMagick on Ubuntu 20.04 LTS. Before continuing with this tutorial, make sure you are logged in as a user with sudo privileges. All the commands in this tutorial should be run as a non-root user.

ImageMagick is a popular multi-platform image manipulation tool. It can read and write images in a variety of formats like GIF, JPEG, PNG, Postscript, and TIFF. Currently, ImageMagick Studio LLC manages application development. Furthermore, it was first released on August 1, 1990.

Install ImageMagick on Ubuntu 20.04

Step 1. First, before you start installing any package on your Ubuntu server, we always recommend making sure that all system packages are updated.

Step 2. Installing ImageMagick on the Ubuntu system.

  • Installing ImageMagick using apt:

ImageMagick is available from the default Ubuntu repositories, and it can simply be installed by running the apt install command. with Apt command:

  • Install ImageMagick in Ubuntu using compiling source code:

Download the source code from the official website of ImageMagick:

Next, configure dynamic linker run-time bindings:

Step 3. Installing Imagick PHP Extension.

Now, you need to install the Imagick PHP extension, So that we can use it through PHP code:

Reload Apache service to enable PHP extension using the following command:

Now verify that module is enabled properly:

That’s all you need to do to install ImageMagick on Ubuntu 20.04 Focal Fossa. I hope you find this quick tip helpful. If you have questions or suggestions, feel free to leave a comment below.