-
Notifications
You must be signed in to change notification settings - Fork 30.7k
Statically imported image in Next 16.2 (Pages Router) breaks next dev in Safari 26.4 #92118
Description
Link to the code that reproduces this issue
https://github.com/lsvs/next-16.2-statically-imported-image-bug-safari-reproduction-pages
To Reproduce
- Start the app in development mode with
next dev. - Open the app in Safari 26.4 on macOS Sequoia.
- The page immediately crashes with the runtime error:
Runtime Error
Image with src "/_next/static/media/image.3_pmqoemjixc0.png?ts=..." is using a query string which is not configured in images.localPatterns.
Current vs. Expected behavior
Current behavior:
In Safari 26.4, a statically imported image used with the Pages Router in Next 16.2.1-canary.13 crashes the page in development with an error about a query string not being configured in images.localPatterns. The same code runs without issue in Chrome and Firefox.
Expected behavior:
A statically imported image should work out of the box with the Pages Router in development, without requiring any images.localPatterns configuration, and should behave consistently across browsers (Safari, Chrome, Firefox).
Provide environment information
Operating System:
Platform: darwin
Arch: arm64
Version: Darwin Kernel Version 24.6.0: Fri Feb 27 19:30:16 PST 2026; root:xnu-11417.140.69.709.8~1/RELEASE_ARM64_T8112
Available memory (MB): 24576
Available CPU cores: 8
Binaries:
Node: 22.22.0
npm: 11.11.0
Yarn: 1.22.22
pnpm: 10.33.0
Relevant Packages:
next: 16.2.1-canary.13 // Latest available version is detected (16.2.1-canary.13).
eslint-config-next: N/A
react: 19.2.4
react-dom: 19.2.4
typescript: 5.9.3
Next.js Config:
output: N/AWhich area(s) are affected? (Select all that apply)
Image (next/image), Pages Router
Which stage(s) are affected? (Select all that apply)
next dev (local)
Additional context
I tested the reproduction against:
- 16.1.7 → works as expected
- 16.2.x (including
16.2.1-canary.13) → bug is present
This appears to be a regression introduced between 16.1.7 and 16.2.x.
- The issue is reproducible locally on macOS Sequoia.
- It only happens in Safari; Chrome and Firefox work fine with the same dev server and code.
- The reproduction uses a statically imported image in a Pages Router page without additional
next.config.jsimage configuration.