laravel / laravel/nova-issues

Prevent showing the login page when the user is already logged in

Open
#6,877 4 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
No language data
Stars
557
Forks
33
PR merge metrics
No merged PRs in 30d

Description

- Laravel Version: 12.18.0
- Nova Version: 5.7.3
- PHP Version: 8.4.1
- Database Driver & Version: Mysql 8.0.40
- Operating System and Version: MacBook Pro
- Browser type and version: Chrome 137.0.7151.104
- Reproduction Repository: https://gitlab.com/bvk-dev/laravel-nova

### Description:
Hi guys!
I’m using Laravel 12 and Nova 5, Everything is working fine so far, but I ran into an issue:

When a user is already logged in (authenticated) and navigates to the /nova/login URL, instead of redirecting to the dashboard page (like /nova/dashboards/main or the main Nova page), it still shows the login page.

✅ What I expected:
If the user is already logged in and tries to access the login page, they should be redirected to the dashboard page.

❌ What happens instead:
The login form is shown again to the authenticated user.

### Detailed steps to reproduce the issue on a fresh Nova installation:

https://github.com/user-attachments/assets/53cebfec-f038-4ed1-8494-cd5c4e3ddb37

Contributor guide

No contributing guide indexed for this repository

Research direction

Begin by reproducing the behavior at the /nova/login route using the fresh Nova installation described in the issue. Trace the login entry point and authenticated-user handling, then verify that an authenticated user is redirected to /nova/dashboards/main or the main Nova page instead of seeing the login form.

Written by the indexing model from the issue text.

Assessment

Tech stack
laravel, php
Domain
authentication
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.