Next.js Discord

Discord Forum

Is NextAuth's `getServerSession` also automatically cached like `fetch`?

Unanswered
Nile Crocodile posted this in #help-forum
Open in Discord
Nile CrocodileOP
So I've recently stumbled upon [this](https://nextjs.org/docs/app/building-your-application/data-fetching/patterns#fetching-data-where-its-needed) in Next.js docs, saying we can make as much fetch requests as we want without worrying about performance, since those requests are automatically memoized by Next.js.
Does this apply to [getServerSession](https://next-auth.js.org/configuration/nextjs#getserversession) in NextAuth? Can I call it as much as I want, wherever I want and not worry about performance? Are those requests also memoized?

0 Replies