Level 15
Yes.
1 like
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
Hello
If I install Laravel Breeze it will support API via Laravel Sanctum ?
composer require laravel/breeze --dev
php artisan breeze:install
php artisan migrate
npm install
npm run dev
Laravel 9.x now comes automatically with Sanctum configured and installed.
So your API in the Breeze project will use Sanctum for authentication, if that's what you are asking.
If you aren't using domain localhost for both your API and frontend, then don't forget to setup your .env file correctly.
You'll probably need one or both of these to prevent a 419 Session Expired error.
SESSION_DOMAIN=.example.com
SANCTUM_STATEFUL_DOMAINS=.api.example.com
Otherwise it should come out of the box ready to go.
Please or to participate in this conversation.