T3 Stack · Concept
NextAuth.js
Create T3 App uses NextAuth.js or Auth.js to provide sessions, OAuth providers, and protected tRPC procedures. Read sessions on the client with useSession or on the server with the provided auth helper.
Last updated
Syntax
const session = await auth();
const { data: session } = useSession();In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.
SubscribeRelated
SessionProvideruseSessionauthgetServerAuthSessionprotectedProcedureDiscordProviderPrisma adaptertRPC