Laravel Architecture

The standard directory structure of Laravel looks like this.

Root Directories
Root Directories


We will discuss the important files and directories before starting our coding.

public/: You have to point your web server to the public directory. It can also be used to put public assets like css, Js, images and other files.

app/: app directory contains the most important files of your application. It has controllers, models and views. You are going to spend most of your time here.

As I said app is the most important directory, so lets discuss a little more about it.

app/ sub-directories and files

app/config/: This directory contains configuration  files like database and app settings.

app/controller/: This contains controller classes.

app/models/: This contains model classes.

app/views/: This contains the HTML template files.

app/routes.php: Route file is to define the routing rules for the app. We will learn about it later.

app/filters.php: This file is to define route filters methods. We will discuss it later.


Share this article: