You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I’m experiencing an issue where the page visually updates after login, but the URL remains stuck on /login. Additionally, signing out does not work unless the page is manually refreshed. It started happening after upgrading Next.js, NextAuth.js, and React to the latest versions.
Run npx auth secret or put your AUTH_SECRET to the .env file
Run the app npm run dev
Visit /login and sign in.
The page visually changes to the home page, but the URL remains stuck at /login.
Clicking “Sign Out” at this point does nothing.
Manually refreshing the page updates the URL correctly to /, and the sign-out button starts working.
I have recorded a demo video to explain the issue.
Screen.Recording.2025-02-27.at.12.07.31.AM.mov
Expected behavior
After logging in, the URL should update correctly to / without requiring a manual refresh.
The sign-out button should function properly without needing a hard refresh.
The text was updated successfully, but these errors were encountered:
hashirshoaeb
added
bug
Something isn't working
triage
Unseen or unconfirmed by a maintainer yet. Provide extra information in the meantime.
labels
Feb 26, 2025
Environment
Reproduction URL
https://github.com/hashirshoaeb/next-auth-test-app
Describe the issue
I’m experiencing an issue where the page visually updates after login, but the URL remains stuck on /login. Additionally, signing out does not work unless the page is manually refreshed. It started happening after upgrading Next.js, NextAuth.js, and React to the latest versions.
Previously Working Setup:
Updated Setup (Causing Issue):
#12697 looks similar issue.
How to reproduce
Steps to Reproduce:
npm install
npx auth secret
or put your AUTH_SECRET to the .env filenpm run dev
I have recorded a demo video to explain the issue.
Screen.Recording.2025-02-27.at.12.07.31.AM.mov
Expected behavior
The text was updated successfully, but these errors were encountered: