Laravel Application Structure

Laravel Root Directory

S.No. Directory/File Description
1 /app This directory contains all of your application’s core code
2 /bootstrap This directory contains all those files required to bootstrap the framework and configure auto-loading
3 /config This directory contains all the application configuration files
4 /database This directory contains all the database migrations and seeds. It can also be used to store the SQLite DB
5 /public This directory contains the front controllers and all the application assets such as images, CSS and JavaScript
6 /resources This directory contains views , language files and un-compiled assets such as LESS, SASS or JavaScript
7 /routes This directory contacins all of the route definitions for your application.
8 /storage This directory contains compiled blade templates, filed based sessions and file cache
9 /tests This directory contains all your automated unit tests for application
10 /vendor This directory contains all the composer dependencies

Laravel App Directory

S.No. Directory/File Description
1 /app/Console This directory contains all of your artisan commands
2 /app/Events This directory contains all your event classes, though it is not created by default
3 /app/Exceptions This directory contains all your exception handlers
4 /app/Http This is directory contains all your controllers, middleware and form requests
5 /app/Jobs This directory contains all queueable jobs, though it is not created by default
6 /app/Listeners This directory contains event handler classes, though it is not created by default
7 /app/Mail This directory contains all your classes required to send emails, though it is not created by default
8 /app/Notifications This directory contains all the notifications sent by application, though it is not created by default
9 /app/Policies This directory contains all the authorization policy classes for your application, though it is not created by default
10 /app/Providers This directory contains all of the service providers for your application.

Laravel Framework Files

S.No. Directory/File Description
1 .env It contains environment variables for application
2 .env.example It contains environment variables for application
3 .gitattributes It is Git configuration files
4 .gitignore It is Git configuration files
5 artisan It allows you to run Artisan commands
6 composer.json It is configuration file for Composer
7 composer.lock It is configuration file for Composer
8 gulpfile.js It is configuration file for Elixir and Gulp
9 package.json It is like composer.json but for frontend assets
10 phpunit.xml It is is a configuration file for PHPUnit
11 readme.md It contains general information about framework
12 server.php It works as internal web server