Download Composer

Run this in your terminal or command prompt to get the latest Composer version :

curl -s | php --
curl -sS | php

or if you don't have curl :

php -r "readfile('');" | php


After downloading the composer file execute the below command for downloading libraries.

For update the composer file

php composer.phar self-update

For downloading the libraries

php composer.phar update (or install)



This installer script will simply check some php.ini settings, warn you if they are set incorrectly, and then download the latest composer.phar in the current directory

Installer Options


You can install composer to a specific directory by using the --install-dir option and providing a target directory. Options must be appended to -- so that PHP ignores them, like -- --install-dir=bin, example :

curl -sS | php -- --install-dir=bin



You can specify the filename (default: composer.phar) using the --filename option. example :

curl -sS | php -- --filename=composer



You can install composer to a specific release by using the --version option and providing a target release. example :

curl -sS | php -- --version=1.0.0-alpha8


Windows Installer

The installer will download composer for you and set up your PATH environment variable so you can simply call composer from any directory.

Download and run  Composer-Setup.exe - it will install the latest composer version whenever it is executed.

  • PHP
  • download
  • composer-phar