Help with Better-Auth in Next.js – useSession Causing 404 Error
Hey everyone!
I’m trying out Better-Auth (v1.1.21) for the first time with Next.js and Postgres. My sign-in and sign-up are working fine, but when I try using useSession inside a client component, I get a 404 error.
I'll share some screenshots for reference. Could this be a session issue or a misconfiguration?
Solution
At auth-client.ts: Change the "better-auth/client" to "better-auth/react"