Installing Composer

Learn how to install Composer on a Linux Ubuntu operating system.

We'll cover the following

Composer is a package manager, which is required to create Symfony projects. In this lesson, we’ll install Composer in the terminal below.

Install Composer

Run the following command to install Composer:

curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer

Check Composer

Check if Composer is installed correctly by checking the version of Composer. To do that, run the following command:

composer -v

You should get an output similar to the one below:

   ______
  / ____/___  ____ ___  ____  ____  ________  _____
 / /   / __ \/ __ `__ \/ __ \/ __ \/ ___/ _ \/ ___/
/ /___/ /_/ / / / / / / /_/ / /_/ (__  )  __/ /
\____/\____/_/ /_/ /_/ .___/\____/____/\___/_/
                    /_/
Composer version 2.4.4 2022-10-27 14:39:29
....

Well done! Now, you have Composer installed.

Get hands-on with 1400+ tech skills courses.