Next.js Discord

Discord Forum

How do I know if unstable_cache() is hit or not?

Unanswered
Bonga shad posted this in #help-forum
Open in Discord
Bonga shadOP
Hi folks,

I used unstable_cache() in my code. However I am not sure if cache is hit or not. How can I tell?

I have tried a couple of things:
- I followed this https://nextjs.org/docs/app/api-reference/next-config-js/logging but I only see something like GET /map/Wisconsin?_rsc=13d4o 200 in 37ms where 37ms is in green in my console. It didn't tell me if cache is hit or not.
- I checked under my Chrome's network tab. The Cache-Control: no-store, must-revalidate line makes me think that cache is not enabled.

Is there a good way to tell if cache is hit or not? Thanks.

1 Reply

Giant panda
Bump!