Next.js InvalidUrl error when I change the domain name
I am getting this error when I changed the railway deployment url. Not sure whats causing it. I'm using Next.js v14
Solution:Jump to solution
New reply sent from Help Station thread:
Yep. That worked (changing NEXTAUTH_URL to AUTH_URL)You're seeing this because this thread has been automatically linked to the Help Station thread....
5 Replies
Project ID:
808d69ee-f688-4ec9-b90d-0be6af1aa4a0
808d69ee-f688-4ec9-b90d-0be6af1aa4a0
have you re-deployed since?
Yep i redeployed. Im testing right now to see if it was because there was no
https://
in front of my shared variable for the public url
Seems to have kind of fixed it. This is only semi-related to railway now
Basically I'm using next-auth and when node.js ran new URL ( public endpoint) without the https://
in front, it errored out. I added it and now I'm getting a weird error with nextauth.
redeploying to see if that has any effect
I'm changing the .env var from "NEXTAUTH_URL" to "AUTH_URL" to see if that fixes. It seems its now using a different version of Auth.js or nextauthSolution
New reply sent from Help Station thread:
Yep. That worked (changing NEXTAUTH_URL to AUTH_URL)You're seeing this because this thread has been automatically linked to the Help Station thread.