Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Login Laravel Package

auth0/login

Auth0 Laravel SDK integrates Auth0 into Laravel apps with no-code user authentication, extensive Management API support, and permissions-based routing access control. Requires Composer, a supported Laravel version, and an Auth0 account.

View on GitHub
Deep Wiki
Context7

Auth0 Laravel SDK. Straight-forward and tested methods for implementing authentication, and accessing Auth0's Management API endpoints.

Frequently asked questions about Login
What is the Auth0 Laravel SDK (auth0/login) used for?
The Auth0 Laravel SDK, installed as auth0/login, is the official Laravel SDK for Auth0 authentication and Management APIs. It adds an Auth0 guard and user provider to Laravel, supports hosted Universal Login, and exposes Management API features such as users, roles, permissions, and organizations. It is a Laravel-native layer over auth0/auth0-php rather than a community-built package.
How do I install and configure auth0/login in Laravel?
Install it with composer require auth0/login, publish config/auth0.php, and set environment values such as AUTH0_DOMAIN, AUTH0_CLIENT_ID, AUTH0_CLIENT_SECRET, AUTH0_COOKIE_SECRET, AUTH0_AUDIENCE, and AUTH0_MANAGEMENT_AUDIENCE. Then point config/auth.php at the Auth0 guard and provider and register the package middleware you need. A typical server-rendered login can be working in under a day.
Which Laravel and PHP versions does auth0/login support?
The package requires a supported Laravel release and a maintained PHP version, following Auth0's support policy; it does not support every historical Laravel or PHP combination. Check the repository support matrix and Packagist release history before committing, because the published metadata can be misleading. The SDK is designed to track current Laravel majors, but you should verify the exact version for your app.
Should I use stateful or stateless mode with the Auth0 Laravel SDK?
Use stateful mode for server-rendered Laravel apps that rely on sessions and cookies, and stateless mode for SPA, mobile, or API clients that send JWT bearer tokens. The choice affects middleware, cookie configuration, and token refresh strategy, so decide before implementation. Retrofitting stateless behavior into a stateful setup is expensive.
Does auth0/login work with Laravel's Auth facade, gates, and policies?
Yes. The SDK registers an auth0 guard driver and user provider, so standard Laravel authorization such as Auth::user(), @auth, gates, and policies continues to work. That is the main architectural benefit: adoption is mostly configuration-level rather than a rewrite of authorization logic. You still need to map Auth0 identities and permissions correctly.
Can I mirror Auth0 users into a local Eloquent model?
Yes, the package can mirror Auth0 users into a local Eloquent model, which helps preserve foreign keys and existing relationships. This is the key migration lever, but validate it in a spike rather than assuming it fits your schema. You remain responsible for sync behavior and conflict handling.
How do I call the Auth0 Management API from Laravel with this package?
The SDK provides in-app access to Auth0's Management API, so you can perform user CRUD, assign roles and permissions, and handle organizations without writing custom HTTP plumbing. You need a Management API audience and appropriate machine-to-machine credentials. Treat these calls carefully in production because they can change identity data directly.
How does permissions-based routing access control work in auth0/login?
The SDK supports permissions-based routing access control, letting you protect routes according to permissions carried in the Auth0 identity. This fits Laravel middleware and authorization patterns, but you should define a clear permission model and test it. Do not rely on route protection alone for sensitive operations; enforce checks in policies too.
Is auth0/login safe for production and what happens if Auth0 is down?
Production risk centers on availability coupling and configuration drift: if Auth0 is unavailable, new logins and token refreshes stop, and there is no local fallback. Callback URLs, allowed origins, logout URLs, and cookie secrets must match across tenant, environment, and app or you get redirect loops that look like application bugs. Reconcile Auth0's SLA and pricing tier with your availability and break-glass requirements.
How does auth0/login compare to Laravel Fortify, Socialite, or generic OIDC, and how hard is migration?
Auth0 is a first-party, vendor-owned identity platform, so the main alternative comparison is Laravel Fortify, Socialite with generic OIDC, Keycloak, Cognito, or WorkOS. Migration away means replacing the guard, re-provisioning users, and reworking session and Management API assumptions, which is typically weeks rather than days. Price that exit option explicitly, especially if procurement or regulation requires an exit plan.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
oxygen/data
oxygen/core
jengo/base
xiloryx/log-collector
a21ns1g4ts/filament-stripe
la-php/laravel-admin
artisan-build/community-prompts
vleroy/smart
ayles-software/laravel-australian-public-holidays
cboxdk/laravel-id-spatie
cboxdk/laravel-id-billing
cboxdk/laravel-id-billing-bridge
simple-as-fuck/php-performance-log
hsluv/hsluv
seampact/codegen
seampact/hooks
seampact/ir
mehedimi/laravel-amp-mail
happones/laravel-vue-i18n-generator
jwerd/inertia-table