How to install Laravel

1. Visit Laravel installation guide at https://laravel.com/docs/5.3/installation

Make sure the following requirements are installed:
PHP >= 5.6.4
OpenSSL PHP Extension
PDO PHP Extension
Mbstring PHP Extension
Tokenizer PHP Extension
XML PHP Extension

Open a terminal and type the command below to check your PHP version.

$ php -v

2. Install Composer, the PHP dependency manager.

Go to https://getcomposer.org/doc/00-intro.md and follow the instructions applicable for your machine.
For macs, run these commands:

$ php composer-setup.php --install-dir=bin --filename=composer
$ mv composer.phar /usr/local/bin/composer

You should be able to run composer now.

$ composer

3. Now you can install PHP packages including Laravel itself.

$ composer global require "laravel/installer"

4. Make sure to place the $HOME/.composer/vendor/bin directory (or the equivalent directory for your OS) in your $PATH so the laravel executable can be located by your system.

On mac, add the following line to your /Users/yourhome/.bash_profile

export PATH="/Users/yourhome/.composer/vendor/bin:$PATH"

5. Now you should be able to start a Laravel project.

$ laravel new my-project

Now open my-project into your editor of choice.

6. You may now, install Sqlite3 http://mislav.net/rails/install-sqlite3/
or MySQL https://dev.mysql.com/downloads/installer/ for database.