DEV Community

Cover image for [next-auth][error][CLIENT_FETCH_ERROR]
Catur Hidayat
Catur Hidayat

Posted on • Updated on

[next-auth][error][CLIENT_FETCH_ERROR]

Hi Coder 👨🏽‍💻

I'm learning full-stack from this course: Build a Full-Stack App...

I'm having trouble get a session using the getSession() function.

[next-auth][error][CLIENT_FETCH_ERROR]
"[next-auth][error][CLIENT_FETCH_ERROR]"

environment file
environment file

This my code...
My Code

i tried to create separate project and use new environment and experienced the same thing.

session return null value
session return null value

i think my code is nothing wrong i have followed step by step and as per documentation.

Please help 🙏🏽

SOLVED!
I just config password application in my google account(sign up with app) - Read this

Top comments (5)

Collapse
 
sebadeh profile image
Sebastián de Haedo

What worked for me was changing the getSession in the handlers for getServerSession.

next-auth.js.org/configuration/nex....

Hope it works!

Collapse
 
brokylabs profile image
Catur Hidayat

Thanks Dude, already Solved!

Collapse
 
hiallhomies profile image
hi-all-homies

tnx man, your advice has helped me a lot.

Collapse
 
monkepi18 profile image
monkepi18

Did you figure it out?
I have the same error. Please help.

Collapse
 
overnight profile image
ovΞrnight

you end up figuring it out?