Laravel 10 Breeze Authentication Example

Created at 30-Jan-2024 , By samar

In this tutorial we will learn how to create a laravel 10 project using the breeze package. Laravel Breeze is a minimalist authentication scaffolding package for Laravel 10. It publishes controllers files, views and routes for authentication system in laravel 10 application. It provides a simple and secure foundation for user login, registration, password reset, email verification, and profile editing, all with beautiful Blade templates and optional Tailwind CSS styling.

Prior to the introduction of Laravel Breeze in Laravel, the laravel/ui package was the go-to option for developers seeking out-of-the-box authentication scaffolding. Offering both Bootstrap and React implementations, it provided pre-built components for login, registration, password reset, and email verification. However, due to its broader scope and additional features, laravel/ui came with a bit more setup complexity than the streamlined minimalism of Breeze.

Step 1: Install the Laravel project

First open the window terminal and Install a new laravel application using the below command.

composer create-project laravel/laravel example-app

Step 2 : Move to the project directory

cd example-app

Step 3: Add breeze package to Laravel

composer require laravel/breeze

Step 4 : Install laravel breeze for simple auth scaffolding. So let's run the command below.

php artisan breeze:install

Now you will get the below option to choose.

Which Breeze stack would you like to install?
  Blade with Alpine ................................................................................... blade  
  Livewire (Volt Class API) with Alpine ............................................................ livewire  
  Livewire (Volt Functional API) with Alpine ............................................ livewire-functional  
  React with Inertia .................................................................................. react  
  Vue with Inertia ...................................................................................... vue  
  API only .............................................................................................. api  

Choose the first option (Blade with Alpine) by entering blade in command prompt and pass other options as per your requirement.

Step 5 : Create a database in MySQL and add database name in .env file and run below migration command in your terminal.

php artisan migrate

Step 6 : Now you can run the php artisan serve command to start the development server and visit to http://localhost:8000/ URL.

php artisan serve

If you like what you are reading, please consider buying us a coffee ( or 2 ) as a token of appreciation.

Buy Me A Coffee

Don't forget to share this article! Help us spread the word by clicking the share button below.

We appreciate your support and are committed to providing you valuable and informative content.

We are thankful for your never ending support.