vercel / vercel/next.js

How to generate ETag for static pre-rendered pages in Next.js 15?

Open
#80,452 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Loading UI and Streaming
Dominant language
JavaScript
Stars
142k
Forks
32.4k
Avg merge
2d 14h
Merged PRs (30d)
351

Description

Link to the code that reproduces this issue

https://github.com/build24001/static-etag

To Reproduce

1.npm run build
2.npm run start
3.Refresh the homepage
4.Observe that the pre-rendered RSC request is 200 every time

Current vs. Expected behavior

Description:
In Next.js 14, static pre-rendered pages could generate ETags. In Next.js 15, since React Server Components (RSC) are streamed by default, ETags cannot be generated.
Is there any way to disable streaming and enable ETag generation?

Provide environment information
Operating System:
  Platform: darwin
  Arch: arm64
  Version: Darwin Kernel Version 24.3.0: Thu Jan  2 20:24:24 PST 2025; root:xnu-11215.81.4~3/RELEASE_ARM64_T6030
  Available memory (MB): 18432
  Available CPU cores: 12
Binaries:
  Node: 18.20.1
  npm: 10.5.0
  Yarn: N/A
  pnpm: 9.7.0
Relevant Packages:
  next: 15.3.3 // Latest available version is detected (15.3.3).
  eslint-config-next: 15.3.3
  react: 19.1.0
  react-dom: 19.1.0
  typescript: 5.8.3
Next.js Config:
  output: N/A
Which area(s) are affected? (Select all that apply)

Loading UI and Streaming

Which stage(s) are affected? (Select all that apply)

Other (Deployed)

Additional context

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Use the linked static-etag reproduction: run npm run build, npm run start, and refresh the homepage to confirm the RSC request remains 200. Then investigate whether Next.js 15 exposes a supported way to disable streaming and generate ETags; done means a confirmed configuration or documented limitation.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, nextjs, react
Domain
web-dev
Issue type
Bug
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.