Spread the love

Laravel is most popular framework of PHP. It provides lots of in-build tools and library to build the web application. laravel community has working quite hard to make the laravel most efficient and secured framework for web developers that’s why most of the websites are built with laravel as backend. Laravel is used to to create robust custom web applications with ease of amazing developer experience.

Laravel add some new features in laravel and here are the nutshell

Laravel is easily customizable and provides tools like ORM, Validation libraries, Queue, Mail, Routing, Schedulers, Views engines and Model view controller architecture.

Installing Laravel using composer

To install the Laravel 10 using the composer there is few requirements which are below:

# Requirements:

  1. PHP 8.1+ for Laravel 10
  2. BCMath PHP Extension
  3. Ctype PHP Extension
  4. Fileinfo PHP extension
  5. JSON PHP Extension
  6. Mbstring PHP Extension
  7. OpenSSL PHP Extension
  8. PDO PHP Extension
  9. Tokenizer PHP Extension

Read how to install extensions and php and What is composer and how to install composer?.

After checking the requirements, now we can start the installation.

First step is to open the command line in windows or terminal in Ubuntu and go to the folder where you want to install the Laravel. Most probably the directory of web server (var/www/html or htdocs)

$ composer create-project laravel/laravel example-app

here, example-app is the name of project.

This will show result as below

Getting error like below



PHP Fatal error:  Allowed memory size of 1610612736 bytes exhausted

then change composer memory limit and run composer update in example-app

 COMPOSER_MEMORY_LIMIT=-1  composer update

And the directory structure after installation

Laravel directory structure

then change composer memory limit and run composer update in example-app

If you are getting error Laravel 10 – Error During installation laravel/framework[v10.0.0] require composer-runtime-api ^2.2 – Solved then you can read this article

Check the installation in browser by opening URL http://domain_ip/example-app/public

Leave a Reply