In laravel 11, Breeze is a lightweight authentication system that provides you auth scaffolding features for the use of default login, registration, password reset, and email verification designed pages in Laravel applications.
In this guide, we will show you how to develop an authentication system using breeze auth in laravel 11 applications.
Steps on Laravel 11 Breeze Authentication Scaffolding Tutorial
Here are steps:
Step 1 – Download New Laravel Application
Open cmd and run the following command to install and setup new laravel 11 application into your server:
//for windows user cd xampp/htdocs //for ubuntu user cd var/www/html
composer create-project --prefer-dist laravel/laravel BreezeAuth11
Step 2 – Configure App with Database
Open .env
file from root folder of laravel application and configure database in it; something like this:
DB_CONNECTION=mysql DB_HOST=127.0.0.1 DB_PORT=3306 DB_DATABASE=db name DB_USERNAME=db user name DB_PASSWORD=db password
Step 3 – Install and Set UP Breeze Auth
Run the composer require laravel/breeze --dev
on cmd to install breeze auth in the application:
composer require laravel/breeze --dev php artisan breeze:install
Step 4 – Run Migration
To create a table into your database, run the following command on cmd:
php artisan migrate
Step 5 – Install NPM packages
Run npm install && npm run dev
command on cmd to install required npm packages in the application:
npm install
npm run dev
Step 6 – Run Application Server
Open new cmd window and navigate to application folder using cd
command, and then run the php artisan serve
command in it to create tables in database:
cd /xampp/htdocs/BreezeAuth11 php artisan serve
Now, open browser and hit the following url on it:
http://127.0.0.1:8000/