diff --git a/docs/01-app/03-api-reference/04-functions/fetch.mdx b/docs/01-app/03-api-reference/04-functions/fetch.mdx index d7154959b92a7..a0878a140bafb 100644 --- a/docs/01-app/03-api-reference/04-functions/fetch.mdx +++ b/docs/01-app/03-api-reference/04-functions/fetch.mdx @@ -49,7 +49,8 @@ Configure how the request should interact with Next.js [Data Cache](/docs/app/bu fetch(`https://...`, { cache: 'force-cache' | 'no-store' }) ``` -- **`no-store`** (default): Next.js fetches the resource from the remote server on every request without looking in the cache, and it will not update the cache with the downloaded resource. +- **`auto no cache`** (default): Next.js fetches the resource from the remote server on every request in development, but will fetch once during `next build` because the route will be statically prerendered. If [Dynamic APIs](/docs/app/building-your-application/rendering/server-components#dynamic-rendering) are detected on the route, Next.js will fetch the resource on every request. +- **`no-store`**: Next.js fetches the resource from the remote server on every request, even if Dynamic APIs are not detected on the route. - **`force-cache`**: Next.js looks for a matching request in its Data Cache. - If there is a match and it is fresh, it will be returned from the cache. - If there is no match or a stale match, Next.js will fetch the resource from the remote server and update the cache with the downloaded resource. @@ -83,11 +84,11 @@ Set the cache tags of a resource. Data can then be revalidated on-demand using [ ## Troubleshooting -### Fetch `cache: 'no-store'` not showing fresh data in development +### Fetch default `auto no store` and `cache: 'no-store'` not showing fresh data in development Next.js caches `fetch` responses in Server Components across Hot Module Replacement (HMR) in local development for faster responses and to reduce costs for billed API calls. -By default, the [HMR cache](/docs/app/api-reference/config/next-config-js/serverComponentsHmrCache) applies to all fetch requests, including those with the `cache: 'no-store'` option. This means uncached requests will not show fresh data between HMR refreshes. However, the cache will be cleared on navigation or full-page reloads. +By default, the [HMR cache](/docs/app/api-reference/config/next-config-js/serverComponentsHmrCache) applies to all fetch requests, including those with the default `auto no cache` and `cache: 'no-store'` option. This means uncached requests will not show fresh data between HMR refreshes. However, the cache will be cleared on navigation or full-page reloads. See the [`serverComponentsHmrCache`](/docs/app/api-reference/config/next-config-js/serverComponentsHmrCache) docs for more information.